PEP 276 Simple Iterator for ints

Magnus Lie Hetland mlh at idi.ntnu.no
Tue Nov 13 17:42:00 EST 2001


<James_Althoff at i2.com> wrote in message
news:mailman.1005687619.18024.python-list at python.org...
> All,
>
> Below is the first draft of PEP 276 "Simple Iterator for ints".
> (Available at http://python.sourceforge.net/peps/pep-0276.html)

Heh -- cool :)

I'd love to drop range() or xrange() from my for loops... (I would
like some pseudocode-like literal like 0..n myself, but I see
the [0:n] PEP has been rejected, so... :|)

The x, = 1 thingy is pretty ugly, though... Let's just hope that
iterators don't become indexable... 5[2] is just too weird ;)

--
Magnus Lie Hetland                           The Anygui Project
http://hetland.org                           http://anygui.sf.net






More information about the Python-list mailing list