l...@gnu.org (Ludovic Courtès) writes: > Currently the behavior of ‘throw’ (in boot-9.scm) is that it always > aborts to the catch prompt and runs the ‘throw’ handler from there; the > continuation of the faulty code is not captured, and thus cannot be > resumed like MIT Scheme’s (restart 2) does: > > (call-with-prompt > tag > (lambda () > (with-fluids > ((%exception-handler > (if pre-unwind-handler > (custom-throw-handler tag k pre-unwind-handler) > (default-throw-handler tag k)))) > (thunk))) > (lambda (cont k . args) ;<- here we would want to call CONT > (apply handler k args))) > > We would need to make this customizable. However, we don’t want to > systematically reify ‘cont’ here because that would be too costly.
I guess we crossed messages... If I interpret correctly, this code is taken from 'with-throw-handler'. In the toy restart that I sent I'm taking the continuation within an error procedure. Thus, if no condition is signaled, no continuation needs to be taken. But I've not really thought things thru and maybe it is too simplistic. Regards, Fede