diff options
Diffstat (limited to 'erts/doc/src/match_spec.xml')
-rw-r--r-- | erts/doc/src/match_spec.xml | 32 |
1 files changed, 27 insertions, 5 deletions
diff --git a/erts/doc/src/match_spec.xml b/erts/doc/src/match_spec.xml index 65a886fe96..988f895dde 100644 --- a/erts/doc/src/match_spec.xml +++ b/erts/doc/src/match_spec.xml @@ -4,7 +4,7 @@ <chapter> <header> <copyright> - <year>1999</year><year>2021</year> + <year>1999</year><year>2022</year> <holder>Ericsson AB. All Rights Reserved.</holder> </copyright> <legalnotice> @@ -113,8 +113,9 @@ <c><![CDATA[length]]></c> | <c><![CDATA[map_get]]></c> | <c><![CDATA[map_size]]></c> | <c><![CDATA[node]]></c> | <c><![CDATA[round]]></c> | <c><![CDATA[size]]></c> | - <c><![CDATA[bit_size]]></c> | + <c><![CDATA[bit_size]]></c> | <c><![CDATA[byte_size]]></c> | <c><![CDATA[tl]]></c> | <c><![CDATA[trunc]]></c> | + <c><![CDATA[binary_part]]></c> | <c><![CDATA['+']]></c> | <c><![CDATA['-']]></c> | <c><![CDATA['*']]></c> | <c><![CDATA['div']]></c> | <c><![CDATA['rem']]></c> | <c><![CDATA['band']]></c> | @@ -139,6 +140,7 @@ <c><![CDATA[process_dump]]></c> | <c><![CDATA[enable_trace]]></c> | <c><![CDATA[disable_trace]]></c> | <c><![CDATA[trace]]></c> | <c><![CDATA[display]]></c> | <c><![CDATA[caller]]></c> | + <c><![CDATA[caller_line]]></c> | <c><![CDATA[set_tcw]]></c> | <c><![CDATA[silent]]></c> </item> </list> @@ -195,8 +197,9 @@ <c><![CDATA[length]]></c> | <c><![CDATA[map_get]]></c> | <c><![CDATA[map_size]]></c> | <c><![CDATA[node]]></c> | <c><![CDATA[round]]></c> | <c><![CDATA[size]]></c> | - <c><![CDATA[bit_size]]></c> | + <c><![CDATA[bit_size]]></c> | <c><![CDATA[byte_size]]></c> | <c><![CDATA[tl]]></c> | <c><![CDATA[trunc]]></c> | + <c><![CDATA[binary_part]]></c> | <c><![CDATA['+']]></c> | <c><![CDATA['-']]></c> | <c><![CDATA['*']]></c> | <c><![CDATA['div']]></c> | <c><![CDATA['rem']]></c> | <c><![CDATA['band']]></c> | @@ -273,7 +276,8 @@ </item> <tag><c>abs</c>, <c>element</c>, <c>hd</c>, <c>length</c>, <c>map_get</c>, <c>map_size</c>, <c>node</c>, <c>round</c>, - <c>size</c>, <c>bit_size</c>, <c>tl</c>, <c>trunc</c>, <c>'+'</c>, + <c>size</c>, <c>bit_size</c>, <c>byte_size</c>, <c>tl</c>, + <c>trunc</c>, <c>binary_part</c>, <c>'+'</c>, <c>'-'</c>, <c>'*'</c>, <c>'div'</c>, <c>'rem'</c>, <c>'band'</c>, <c>'bor'</c>, <c>'bxor'</c>, <c>'bnot'</c>, <c>'bsl'</c>, <c>'bsr'</c>, <c>'>'</c>, <c>'>='</c>, <c>'<'</c>, <c>'=<'</c>, @@ -435,6 +439,24 @@ <c><![CDATA[undefined]]></c>. The calling Erlang function is not available during such calls.</p> </item> + <tag><c>caller_line</c></tag> + <item> + <p>Similar to <c>caller</c> but returns additional information about + the source code location of the function call-site within the + caller function. Returns the calling function as a tuple + <c>{Module, Function, Arity, {File, Line}}</c>. <c>File</c> is the + <seeguide marker="system/reference_manual:data_types#string">string</seeguide> + file name while <c>Line</c> is source line number. If the <c>File</c> + and <c>Line</c> cannot be determined, <c>{Module, Function, Arity, undefined}</c> + is returned. If the calling function cannot be determined, the atom + <c><![CDATA[undefined]]></c> is returned. Can only be used in the + <c><![CDATA[MatchBody]]></c> part when tracing.</p> + <p>Notice that if a "technically built in function" (that is, a + function not written in Erlang) is traced, the + <c><![CDATA[caller_line]]></c> function sometimes returns the atom + <c><![CDATA[undefined]]></c>. The calling + Erlang function is not available during such calls.</p> + </item> <tag><c>display</c></tag> <item> <p>For debugging purposes only. Displays the single argument as an @@ -867,7 +889,7 @@ ['$_']}] ]]></code> - <p>Function <seemfa marker="stdlib:ets#test_ms/2"><c>ets:test_ms/2></c></seemfa> + <p>Function <seemfa marker="stdlib:ets#test_ms/2"><c>ets:test_ms/2</c></seemfa> can be useful for testing complicated ETS matches.</p> </section> </chapter> |