[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Abominations of nature (was: Features you would like to see)
- From: roberto@... (Roberto Ierusalimschy)
- Date: Wed, 22 Aug 2007 14:02:17 -0300
> I'm not sure I'm following you. Continuations have state, just
> like closures do, in the form of local variables and lexically-scoped
> variables.
When you capture a continuation you capture its local variables, not the
current values of these variables (at least in Scheme). If you modify
a local variable and later call the captured continuation, the variable
does not "roll back" to its value when the continuation was saved.
But more important, as Mike Pall just pointed out, is that real programs
in non-functional languages have lots of state outside its local
variables (globals, mutable objects, files, etc.). None of them are part
of a continuation.
-- Roberto
- References:
- Re: Features you would like to see, Alex Queiroz
- Re: Features you would like to see, David Kastrup
- Abominations of nature (was: Features you would like to see), David Given
- Re: Abominations of nature (was: Features you would like to see), Fabien
- Re: Abominations of nature (was: Features you would like to see), Roberto Ierusalimschy
- Re: Abominations of nature (was: Features you would like to see), Alex Queiroz
- Re: Abominations of nature (was: Features you would like to see), Roberto Ierusalimschy
- Re: Abominations of nature (was: Features you would like to see), Alex Queiroz
- Re: Abominations of nature (was: Features you would like to see), Roberto Ierusalimschy
- Re: Abominations of nature (was: Features you would like to see), Alex Queiroz