saving / restoring the stack?

Chermside, Michael mchermside at ingdirect.com
Tue Mar 18 18:12:39 CET 2003


Clark Evans writes:
> Hello.  I have a strange request.  I was wondering if it is
> possible to "save" the current stack; unwind down say 3 
> levels, do some stuff down there, and then resume execution
> back up where I was before?  It is possible to have two
> saved stacks?

sismex01 has already stolen <wink> my best two responses:
"Generators may help", and "Stackless allows this". But I
think if you describe just exactly what you're trying to do
that, while I may or may not be able to make a practical
suggestion, I'll at least learn something in the process.

Curiously,

-- Michael Chermside





More information about the Python-list mailing list