aboutsummaryrefslogtreecommitdiffstats
path: root/lib/syntax_tools/src/erl_prettypr.erl
diff options
context:
space:
mode:
authorHans Bolinder <[email protected]>2016-07-07 09:08:16 +0200
committerHans Bolinder <[email protected]>2016-07-07 09:08:16 +0200
commitca4000874a198b218fd62b90e842475d2a0bb8c7 (patch)
treed5d77cf4a1fa0adb47a36346a89ac08af482c569 /lib/syntax_tools/src/erl_prettypr.erl
parent62ef9f77d94563a03b8f1f5f1e8843f022329393 (diff)
parent531708281a3a2cf336dc92651ede8d9d95f331cb (diff)
downloadotp-ca4000874a198b218fd62b90e842475d2a0bb8c7.tar.gz
otp-ca4000874a198b218fd62b90e842475d2a0bb8c7.tar.bz2
otp-ca4000874a198b218fd62b90e842475d2a0bb8c7.zip
Merge branch 'hasse/erl_docgen/generated_type_links/ERL-120/OTP-13720' into maint
* hasse/erl_docgen/generated_type_links/ERL-120/OTP-13720: wx: Prepare for using Erlang types and specs syntax_tools: Improve types syntax_tools: Improve seealso:s referring to types erl_docgen: Allow 'seealso' in 'name' erl_docgen: Generate type links in callback module creating erlref erl_docgen: Correct callback module for creating erlref erl_docgen: Improve callback module for creating erlref edoc: Correct types
Diffstat (limited to 'lib/syntax_tools/src/erl_prettypr.erl')
-rw-r--r--lib/syntax_tools/src/erl_prettypr.erl21
1 files changed, 13 insertions, 8 deletions
diff --git a/lib/syntax_tools/src/erl_prettypr.erl b/lib/syntax_tools/src/erl_prettypr.erl
index f1615b2610..df0d78031c 100644
--- a/lib/syntax_tools/src/erl_prettypr.erl
+++ b/lib/syntax_tools/src/erl_prettypr.erl
@@ -195,10 +195,16 @@ format(Node) ->
%% =====================================================================
%% @spec format(Tree::syntaxTree(), Options::[term()]) -> string()
-%% syntaxTree() = erl_syntax:syntaxTree()
%%
-%% @type hook() = (syntaxTree(), context(), Continuation) -> document()
-%% Continuation = (syntaxTree(), context()) -> document().
+%% @type syntaxTree() = erl_syntax:syntaxTree().
+%%
+%% An abstract syntax tree. See the {@link erl_syntax} module for
+%% details.
+%%
+%% @type hook() = (syntaxTree(), context(), Continuation) ->
+%% prettypr:document()
+%% Continuation = (syntaxTree(), context()) ->
+%% prettypr:document().
%%
%% A call-back function for user-controlled formatting. See {@link
%% format/2}.
@@ -277,7 +283,7 @@ format(Node, Options) ->
%% =====================================================================
-%% @spec best(Tree::syntaxTree()) -> empty | document()
+%% @spec best(Tree::syntaxTree()) -> empty | prettypr:document()
%% @equiv best(Tree, [])
-spec best(erl_syntax:syntaxTree()) -> 'empty' | prettypr:document().
@@ -288,7 +294,7 @@ best(Node) ->
%% =====================================================================
%% @spec best(Tree::syntaxTree(), Options::[term()]) ->
-%% empty | document()
+%% empty | prettypr:document()
%%
%% @doc Creates a fixed "best" abstract layout for a syntax tree. This
%% is similar to the `layout/2' function, except that here, the final
@@ -310,7 +316,7 @@ best(Node, Options) ->
%% =====================================================================
-%% @spec layout(Tree::syntaxTree()) -> document()
+%% @spec layout(Tree::syntaxTree()) -> prettypr:document()
%% @equiv layout(Tree, [])
-spec layout(erl_syntax:syntaxTree()) -> prettypr:document().
@@ -320,8 +326,7 @@ layout(Node) ->
%% =====================================================================
-%% @spec layout(Tree::syntaxTree(), Options::[term()]) -> document()
-%% document() = prettypr:document()
+%% @spec layout(Tree::syntaxTree(), Options::[term()]) -> prettypr:document()
%%
%% @doc Creates an abstract document layout for a syntax tree. The
%% result represents a set of possible layouts (cf. module `prettypr').