[plt-scheme] finally

From: Matthias Felleisen (matthias at ccs.neu.edu)
Date: Wed Dec 21 16:21:49 EST 2005

On Dec 21, 2005, at 4:14 PM, Eli Barzilay wrote:

>
>> But I think you're right, with-handlers is better than using
>> dynamic-wind, because it will only catch exceptions and not other
>> transfers of control.  For example, if the try expression is opening
>> a port, you want to close the port if the expression completes
>> normally or if there's an exception, but if it jumps to another
>> continuation and then jumps back you want to leave it open.
>
> That's a sticky issue -- I think that there was a discussion about
> this on c.l.s a few years ago, with all kinds of suggestions like
> weird ways of jumping to a continuation in a way that bypasses
> dynamic-wind.

See Dorai Sitaram's Scheme 2003 workshop paper.

Jesse Tov (cc'ed) has also worked through this issue for the past four 
weeks so he may wish to contribute his insights.

-- Matthias



Posted on the users mailing list.