[erlang-questions] erlang:exit/1 and erlang:exit/2
Wed Jul 30 12:40:59 CEST 2014
Note that exit/1 and exit/2 are completely different functions, hence the
difference in implementation complexity. exit/1 is similar to error/1 and
throw/1, while exit/2 would have been better named signal/2.
On Tue, Jul 29, 2014 at 9:19 PM, Leo Liu <sdl.web@REDACTED> wrote:
> Hi there,
> Could someone help me understand the implementation of erlang:exit/1?
> BIF_RETTYPE exit_1(BIF_ALIST_1)
> BIF_P->fvalue = BIF_ARG_1; /* exit value */
> BIF_ERROR(BIF_P, EXC_EXIT);
> which is pretty simple and I am not sure how it propagates the exit
> signal. erlang:exit/2 on the contrary is full of details.
> erlang-questions mailing list
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the erlang-questions