[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: CPS in Parrot (was: A plea for a new old language)
On Wednesday, August 6, 2003, at 03:47 PM, Dan Sugalski wrote:
> That, though, may be because there's no difference between the
> continuations Parrot uses for its CPS system and continuations it
> takes for call/cc or that it gives you when you just want a
> continuation for later use.
OK perhaps someone can clear up some confusion for me.
Assuming you have a language that has mutable variables, and you can
write a subroutine that happened to use a global variable as a loop
counter and create a first class continuation from within the loop,
wouldn't capturing the continuation include/require copying the global
environment then? If the global environment were not copied then the
continuation could not be resumed more than once with the same
behaviour because the global variable could have been mutated. What
does your system do?
--- james mccartney