From: "Patrick R. Michaud" <[email protected]>
   Date: Sun, 6 Dec 2009 00:01:24 -0600

   TT #1091 and DEPRECATED.pod claim that label-based exception
   handlers are eligible to be removed in 2.1.  I think label-based
   exception handlers are necessary; but I'm willing to be proven wrong.

If a handler "should be" a Sub, then presumably a closure should also be
allowed.  In that case, you could create a closure that contained the
loop_handler body, calling continuations instead of using "goto".  But
not only is that a much more heavy-weight solution, it doesn't avoid the
inferior runloop issue, either.

   Furthermore, if there is an inferior runloop problem with using a
Continuation as a handler, then there is also a problem with invoking a
Continuation from a handler.  And if that is so, then handler code can't
make a nonlocal exit, which seems unacceptable in any case.

   But if a handler can be a Closure or a Sub, and if handlers should be
allowed to make nonlocal exits, then I fail to see the advantage of
eliminating the Continuation case.  It should be possible to use all
classes of invokable objects interchangeably, IMHO -- here as elsewhere.

   So I am puzzled, too.

   OK, back to lurking.  ;-}

                                        -- Bob Rogers
                                           http://www.rgrjr.com/
_______________________________________________
http://lists.parrot.org/mailman/listinfo/parrot-dev

Reply via email to