[Python-checkins] r72646 - python/branches/release30-maint/Doc/library/itertools.rst

raymond.hettinger python-checkins at python.org
Thu May 14 23:52:15 CEST 2009


Author: raymond.hettinger
Date: Thu May 14 23:52:15 2009
New Revision: 72646
Log:
Fix error in 2-to-3 translation of docs.
Modified:
 python/branches/release30-maint/Doc/library/itertools.rst
Modified: python/branches/release30-maint/Doc/library/itertools.rst
==============================================================================
--- python/branches/release30-maint/Doc/library/itertools.rst	(original)
+++ python/branches/release30-maint/Doc/library/itertools.rst	Thu May 14 23:52:15 2009
@@ -294,7 +294,7 @@
 # islice('ABCDEFG', 2, None) --> C D E F G
 # islice('ABCDEFG', 0, None, 2) --> A C E G
 s = slice(*args)
- it = range(s.start or 0, s.stop or sys.maxsize, s.step or 1)
+ it = iter(range(s.start or 0, s.stop or sys.maxsize, s.step or 1))
 nexti = next(it)
 for i, element in enumerate(iterable):
 if i == nexti:


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /