[r6rs-discuss] Reraising continuable exceptions has a problem with `&non-continuable'
derick.eddington at gmail.com
Thu Nov 20 02:38:36 EST 2008
On Wed, 2008-11-19 at 10:12 +0100, Michael Sperber wrote:
> Derick Eddington <derick.eddington at gmail.com> writes:
> > [...] and inner handlers should not have to deal with the problems of
> > outer handlers.
> It seems to me you really want a restart system. (This is something
> Richard Kelsey and I considered while SRFI 34 but decided to defer, as
> it can be done orthogonally to the exception system itself.) Have you
> considered this?
I've been under the impression R6RS's continuable exceptions are its
restarts system. After reading more about restarts, I learned that
Common Lisp restarts  and a proposed system for Scheme  allow
multiple options for how to restart. This sounds very interesting and
like it can be pretty powerful. So far, it seems to me many types of
restarts systems can already be implemented on top of R6RS's conditions,
continuable exceptions, and/or continuations as an independent portable
I don't see how restarts solve the problem with non-continuable
violations that reraising continuable exceptions has. I've started to
really like continuable exceptions, and I want to use them in many ways.
I want to be able to transparently reraise exceptions that I may not
know where they came from, what they mean, or what their handler is
supposed to do (e.g., if it's supposed to return to allow the program to
continue). I don't consider it transparent if a reraising inner handler
has to take into account that it might have to deal with
`&non-continuable' exceptions caused by an outer handler, it already
reraised to, improperly returning. It's my interpretation of the R6RS
that non-continuable violations are intended to be handled by the next
outer handler, just like how any other exception caused by a handler is
handled by the next outer handler. Since the standard has continuable
exceptions, returning handlers, and `&non-continuable' exceptions, I'm
thinking the standard needs a way to transparently reraise that works
with these things. It needs to be part of the standard because
transparently reraising is a core need (right?) and needs to work with
the standard core exceptions system so that various people's code can
work together when combined.
Am I not understanding something?
More information about the r6rs-discuss