In <[EMAIL PROTECTED]>, Peter Otten wrote: > Marc 'BlackJack' Rintsch wrote: > >>>>> from itertools import count >>>>> from sys import maxint >>>>> c = count(maxint) >>>>> c.next() >> 2147483647 >>>>> c.next() >> -2147483648 >> >> What I find most disturbing here, is that it happens silently. I would >> have expected an exception instead of the surprise. > > This is fixed in Python2.5: > >>>> from itertools import count >>>> import sys >>>> c = count(sys.maxint) >>>> c.next(), c.next() > (2147483647, 2147483648L)
Hm, my test above was from 2.5!? Ciao, Marc 'BlackJack' Rintsch -- http://mail.python.org/mailman/listinfo/python-list