Florent Xicluna <la...@yahoo.fr> added the comment:

You will prefer this one. It is as fast as the 2.7 version.
The restrictions are described in the itertools documentation.


from itertools import count, takewhile
irange = lambda start, stop, step: takewhile(lambda x: x<stop, (start+i*step 
for i in count()))

>>> list(irange(-2**65,2**65,2**61))
[-36893488147419103232L, ...

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue7721>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to