[Python-Dev] Breaking off Enhanced Iterators PEP from PEP 340
Steven Bethard
steven.bethard at gmail.com
Fri May 6 22:04:21 CEST 2005
On 5/6/05, Paul Moore <p.f.moore at gmail.com> wrote:
> On 5/6/05, Steven Bethard <steven.bethard at gmail.com> wrote:
> > PEP: XXX
> > Title: Enhanced Iterators
>
> Strawman question - as this is the "uncontroversial" bit, can this
> part be accepted as it stands? :-)
FWIW, I'm +1 on this. Enhanced Iterators
* updates the iterator protocol to use .__next__() instead of .next()
* introduces a new builtin next()
* allows continue-statements to pass values to iterators
* allows generators to receive values with a yield-expression
The first two are, I believe, how the iterator protocol probably
should have been in the first place. The second two provide a simple
way of passing values to generators, something I got the impression
that the co-routiney people would like a lot.
STeVe
--
You can wordify anything if you just verb it.
--- Bucky Katt, Get Fuzzy
More information about the Python-Dev
mailing list