PEP 255: Simple Generators

Erik Max Francis max at alcyone.com
Mon Jun 18 23:27:54 EDT 2001


Tim Peters wrote:

> Abstract
> 
>     This PEP introduces the concept of generators to Python, as well
>     as a new statement used in conjunction with them, the "yield"
>     statement.

This is an extremely clever idea.  It starts with a real problem (the
present awkwardness of a current construct), an analysis of the
solutions, and an elegant proposal for an isolated and clean solution to
the problem.  I'm all for it.

-- 
 Erik Max Francis / max at alcyone.com / http://www.alcyone.com/max/
 __ San Jose, CA, US / 37 20 N 121 53 W / ICQ16063900 / &tSftDotIotE
/  \ There is nothing wrong with sobriety in moderation.
\__/ John Ciardi
    Alcyone Systems' Daily Planet / http://www.alcyone.com/planet.html
 A new, virtual planet, every day.



More information about the Python-list mailing list