[issue19145] Inconsistent behaviour in itertools.repeat when using negative times
Vajrasky Kok
report at bugs.python.org
Fri Jan 24 11:16:39 CET 2014
Vajrasky Kok added the comment:
Here is the updated patch. I try to be conservative here, preserving the current behaviour.
Negative times is same as zero.
Default value (which can be passed by omitting times) means unlimited.
I did not change the signature "repeat(object [,times])" because the only suitable default value, in my opinion, is "repeat(object [,times=<unlimited>])" which is impossible at the moment.
Well, let see what Raymond has anything to say about this.
----------
Added file: http://bugs.python.org/file33681/fix_itertools_repeat_negative_number_means_0_v3.patch
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue19145>
_______________________________________
More information about the Python-bugs-list
mailing list