Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Uncaught exceptions

7 views
Skip to first unread message

Andrew Suffield

unread,
Sep 1, 2006, 4:28:31 AM9/1/06
to perl6-l...@perl.org
What is the behaviour of an *uncaught* exception, particularly with
respect to CHECK/END/LEAVE/LAST blocks, destructors, overloading of
the stringify operator on exception objects, the order in which these
things are executed, and the exit code of the process? (And anything
else that I haven't thought of)

Perl 5's behaviour in this respect is largely undocumented and doing
things during exception-triggered global destruction has a habit of
generating messages about attempting to free unreferenced objects, or
just crashing the interpreter entirely, and I can't see anything in
the synopses about it.

A closely related question here: exactly how much can I assume has
already been executed when writing destructors and ALAP blocks? Do I
have to guard against some of my data mysteriously transmuting into
undef?

0 new messages