Re: [Haskell-cafe] MonadCatchIO and bracket.

2010-06-28 Thread Sterling Clover
There’s a history of rich debate and discussion on these issues coming from the scheme world, where it takes the guise of implementing unwind-protect in the presence of call/cc. Kent Pitman’s take is presented here: http://www.nhplace.com/kent/PFAQ/unwind-protect-vs-continuations-overview.html Th

Re: [Haskell-cafe] MonadCatchIO and bracket.

2010-06-28 Thread Michael Snoyman
On Mon, Jun 28, 2010 at 10:02 PM, Carl Howells wrote: > While working this weekend on the Snap web framework, I ran into a > problem. Snap implements MonadCatchIO, so I thought I could just use > bracket to handle resource acquisition/release in a safe manner. > Imagine my surprise when bracket

Re: [Haskell-cafe] MonadCatchIO and bracket.

2010-06-28 Thread Neil Brown
On 28/06/2010 20:02, Carl Howells wrote: While working this weekend on the Snap web framework, I ran into a problem. Snap implements MonadCatchIO, so I thought I could just use bracket to handle resource acquisition/release in a safe manner. Imagine my surprise when bracket simply failed to run

[Haskell-cafe] MonadCatchIO and bracket.

2010-06-28 Thread Carl Howells
While working this weekend on the Snap web framework, I ran into a problem. Snap implements MonadCatchIO, so I thought I could just use bracket to handle resource acquisition/release in a safe manner. Imagine my surprise when bracket simply failed to run the release action sometimes. I quickly de