[Python-ideas] Revised**7 PEP on Yield-From
greg.ewing at canterbury.ac.nz
Sat Mar 21 02:44:20 CET 2009
Jacob Holm wrote:
> the expansion in your PEP actually has the behaviour you expect
> for the GeneratorExit example because GeneratorExit doesn't inherit from
That's an accident, though, and it's possible I should have
specified BaseException there. I still consider the explanation
I gave to be the true one.
> The other mismatch, concerning the missing "close" calls to the
> iterator, I still believe to be an issue.
Can you elaborate on that? I thought a first you were expecting
the implicit close of the generator that happens before it's
deallocated to be passed on to the subiterator, but some of your
examples seem to have the close happening *before* the del gen,
so I'm confused.
More information about the Python-ideas