Thanks,

   adverse=:2 :0
 try.u y catcht. v y catch. v y end.
:
 try.x u y catcht. x v y catch. x v y end.
)

     (causeAnError adverse ('caught you!'"_) ) ''
caught you!
     (throwAnException adverse ('caught you!'"_) ) ''
caught you!




2009/9/10 Raul Miller <[email protected]>:
> On Thu, Sep 10, 2009 at 11:53 AM, Tracy Harms <[email protected]> wrote:
>> The evaluation of u occurs outside the scope of try. so the value
>> error is not caught:
>
> No.
>
> Value errors are not throws.
>
> Here's the definition Matthew had provided:
>
> throwAnException =: 3 : 0
>  throw.
> )
>
> (Also, I had left an open quote in my example.
> But fixing that should be obvious.)
>
> --
> Raul
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
>



-- 
The risk is socialized, the profit is privatized.
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to