From 229d0d8ca88bc344bed89e46541b325c1d267996 Mon Sep 17 00:00:00 2001 From: Hans Bolinder Date: Fri, 6 May 2011 15:58:09 +0200 Subject: r Use Erlang specs and types for documentation --- lib/stdlib/doc/src/ms_transform.xml | 25 +++++++------------------ 1 file changed, 7 insertions(+), 18 deletions(-) (limited to 'lib/stdlib/doc/src/ms_transform.xml') diff --git a/lib/stdlib/doc/src/ms_transform.xml b/lib/stdlib/doc/src/ms_transform.xml index ba9f89685b..f81f8bda96 100644 --- a/lib/stdlib/doc/src/ms_transform.xml +++ b/lib/stdlib/doc/src/ms_transform.xml @@ -4,7 +4,7 @@
- 20022010 + 20022011 Ericsson AB. All Rights Reserved. @@ -599,12 +599,9 @@ ets:select(Table, [{{'$1',test,'$2'},[],['$_']}]). - parse_transform(Forms,_Options) -> Forms + Transforms Erlang abstract format containing calls to ets/dbg:fun2ms into literal match specifications. - - Forms = Erlang abstract code format, see the erl_parse module description - _Options = Option list, required but not used - + Option list, required but not used.

Implements the actual transformation at compile time. This function is called by the compiler to do the source code @@ -617,29 +614,21 @@ ets:select(Table, [{{'$1',test,'$2'},[],['$_']}]). - transform_from_shell(Dialect,Clauses,BoundEnvironment) -> term() + Used when transforming fun's created in the shell into match_specifications. - - Dialect = ets | dbg - Clauses = Erlang abstract form for a single fun - BoundEnvironment = [{atom(), term()}, ...], list of variable bindings in the shell environment - + List of variable bindings in the shell environment.

Implements the actual transformation when the fun2ms functions are called from the shell. In this case the abstract form is for one single fun (parsed by the Erlang shell), and all imported variables should be in the key-value list passed - as BoundEnvironment. The result is a term, normalized, + as BoundEnvironment. The result is a term, normalized, i.e. not in abstract format.

- format_error(Errcode) -> ErrMessage + Error formatting function as required by the parse_transform interface. - - Errcode = term() - ErrMessage = string() -

Takes an error code returned by one of the other functions in the module and creates a textual description of the -- cgit v1.2.3