Result of catch

Sean Hinde Sean.Hinde@REDACTED
Tue Mar 20 18:33:25 CET 2001


I asked this one a few months back. The answer was something to do with
order of evaluation.

A = (catch 1/0).

- Sean

> 1> catch 1/0.
> {'EXIT',{badarith,[{erl_eval,eval_op,3},
>                    {erl_eval,expr,3},
>                    {erl_eval,exprs,4},
>                    {shell,eval_loop,2}]}}
> 2> 
> 2> A = catch 1/0.
> ** 2: syntax error before: 'catch' **
> 2> 
> 
> I'm a bit surprised by this behaviour. Why can't I store the 
> result of a
> catch?? If I can match on it in a case statement, why can't I 
> just store the
> result?
> 
> tia,
> Chandru
> 



NOTICE AND DISCLAIMER:
This email (including attachments) is confidential.  If you have received
this email in error please notify the sender immediately and delete this
email from your system without copying or disseminating it or placing any
reliance upon its contents.  We cannot accept liability for any breaches of
confidence arising through use of email.  Any opinions expressed in this
email (including attachments) are those of the author and do not necessarily
reflect our opinions.  We will not accept responsibility for any commitments
made by our employees outside the scope of our business.  We do not warrant
the accuracy or completeness of such information.





More information about the erlang-questions mailing list