diff options
author | Sasan Hezarkhani <[email protected]> | 2017-08-24 13:18:34 +0100 |
---|---|---|
committer | Sverker Eriksson <[email protected]> | 2017-08-25 14:42:30 +0200 |
commit | 709c5ed53f282693f1731aff8f0c8080dde872dc (patch) | |
tree | 93887c350b97035d867d47da4cca8fe0d8d6bd77 | |
parent | 3bc5c3b35b3151143dffe94290c9ddf29b1b10d6 (diff) | |
download | otp-709c5ed53f282693f1731aff8f0c8080dde872dc.tar.gz otp-709c5ed53f282693f1731aff8f0c8080dde872dc.tar.bz2 otp-709c5ed53f282693f1731aff8f0c8080dde872dc.zip |
Changes confusing example of a bad guard in ets:fun2ms
-rw-r--r-- | lib/stdlib/doc/src/ets.xml | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/stdlib/doc/src/ets.xml b/lib/stdlib/doc/src/ets.xml index f6f3d18d6a..95af2b77a5 100644 --- a/lib/stdlib/doc/src/ets.xml +++ b/lib/stdlib/doc/src/ets.xml @@ -408,9 +408,9 @@ calls cannot be in the guard or body of the fun. Calls to built-in match specification functions is of course allowed:</p> <pre> -4> <input>ets:fun2ms(fun({M,N}) when N > X, is_atomm(M) -> M end).</input> +4> <input>ets:fun2ms(fun({M,N}) when N > X, my_fun(M) -> M end).</input> Error: fun containing local Erlang function calls -('is_atomm' called in guard) cannot be translated into match_spec +('my_fun' called in guard) cannot be translated into match_spec {error,transform_error} 5> <input>ets:fun2ms(fun({M,N}) when N > X, is_atom(M) -> M end).</input> [{{'$1','$2'},[{'>','$2',{const,3}},{is_atom,'$1'}],['$1']}]</pre> |