Continuations and threads (was Re: Iterators & generators)
Gordon McMillan
gmcm at hypernet.com
Fri Feb 18 08:47:01 EST 2000
Toby Dickenson wrote:
> What are the implications for the continuation-naive in a
> post-stackless world. What about functions such as...
>
> def x():
> before()
> try:
> y()
> finally:
> after()
>
> Today, either of three things happen:
> 1. before() throws
> 2. before() and after() are called exactly once each
> 3. x() never returns because y() never returns
>
> As I understand continuations, we now have the possibility of y()
> returning more than once, with after() called more times than before()
No. In the absence of specific instructions otherwise, the
frame dispatcher will behave as expected.
- Gordon
More information about the Python-list
mailing list