Monadic Call/CC?

Ashley Yakeley ashley@semantic.org
Fri, 22 Feb 2002 02:14:53 -0800


At 2002-02-22 01:36, Richard Uhtenwoldt wrote:

>Yeah, it's called continuation-passing style (CPS).

Good. I have a small collection of wheels I've reinvented in my ignorance.

>So, congratulations, you've written call/cc in Haskell. I think.
>So, what I said this afternoon, namely, that call/cc is
>"not something an implementation is likely
>to be able to support unintentionally", I now have to retract.
>I think.

Well, I have to create my own monad and do call/cc in that. Doing call/cc 
in IO is another matter entirely.

>I guess the call/cc you wrote last night in terms of catch and a ref
>didn't work too well; huh?

I havent't tested it. But I agree that it certainly won't allow 
continuations to survive after peirceM has returned, so can't be 
considered proper call/cc.


-- 
Ashley Yakeley, Seattle WA