On Tuesday, December 30, 2003 5:04 PM, Kevin S. Millikin [SMTP:[EMAIL PROTECTED] wrote: > Oh, sure. I didn't mean to quibble with the idea that continuations > are computational effects. Just wanted to point out that (I think) > you can't macro express mutation with call/cc, unless you've already > got mutation anyway.
[snip] > Yup. If you do that, you can use d as your setter and c as your > getter: > > > (define c (make-cell)) > > (define d c) > > ((d 'set) 9) > > (c 'get) > 9 > > ((d 'set) 17) > > (c 'get) > 17 It sure looks like the example contradicts the assertion, but I happen to know that there is a set! (or some other assignment) in the macro expansion of define. I'm just using call/cc to get at that, rather than getting at the one in the expansion of letrec. Moved to Haskell Cafe. _______________________________________________ Haskell-Cafe mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell-cafe