On Tue, Feb 21, 2006 at 01:07:51PM -, Simon Peyton-Jones wrote:
> I'm not sure this works. Consider this
>
> newContinuation (\k -> return (callContinuation k)) ...
>
> The partial application (callContinuation k) has no 's' in its type, and so
> can go anywhere.
Ah, you are right. si
OTECTED] On Behalf Of John
| Meacham
| Sent: 21 February 2006 12:40
| To: haskell-cafe@haskell.org
| Subject: [Haskell-cafe] typesafe non-local returns in the IO monad
|
| Although I am sure I am not the first to discover this, I thought it was
| a neat application of the runST trick. Safe non-local
Although I am sure I am not the first to discover this, I thought it was
a neat application of the runST trick. Safe non-local returns for
the IO monad. What I mean by safe is that it is impossible to return to
a context that no longer exists. the api is simple:
> module System.IO.Continuation(IOC