[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Scheme mistakes (was Re: nil)
Alan Bawden wrote:
> Date: Thu, 14 Aug 2003 15:01:49 -0500
> From: Matt Hellige <firstname.lastname@example.org>
> Mail-Followup-To: email@example.com
> [Alan Bawden <Alan@lcs.mit.edu>]
> > Consider evaluating:
> > (throw (f x) 42)
> > Since you know that the expression `(f)' must yield a continuation, the
> > old continuation can be discarded (and perhaps reclaimed by the garbage
> > collector) -before- you call the function `f'. If continuations just look
> > like procedures, then the programmer would have written:
> > ((f x) 42)
> > is which case you don't know that the old continuation is going to be
> > discarded until -after- the call to `f' returns a continuation.
> Is this really true? What if `f' causes an error? Mightn't we need the
> old continuation to handle it correctly?
> In pure R5RS Scheme I see no reason that old continuation can't be
But also, in pure R5RS Scheme I see no reason to program.