On Mon, Mar 05, 2007, Ka-Ping Yee wrote: > > Abstract > ======== > > The iterator protocol in Python 2.x consists of two methods: > ``__iter__()`` called on an iterable object to yield an iterator, and > ``next()`` called on an iterator object to yield the next item in the > sequence. Using a ``for`` loop to iterate over an iterable object > implicitly calls both of these methods. This PEP proposes that the > ``next`` method be renamed to ``__next__``, consistent with all the > other protocols in Python in which a method is implicitly called as > part of a language-level protocol, and that a built-in function named > ``next`` be introduced to invoke ``__next__`` method, consistent with > the manner in which other protocols are explicitly invoked.
+1 -- I was always against next() in the first place. I'm +0 on operator.next() relative to builtin next(). -- Aahz ([EMAIL PROTECTED]) <*> http://www.pythoncraft.com/ "I disrespectfully agree." --SJM _______________________________________________ Python-3000 mailing list Python-3000@python.org http://mail.python.org/mailman/listinfo/python-3000 Unsubscribe: http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com