[issue1533] Bug in range() function for large values
Mark Dickinson
report at bugs.python.org
Sun May 2 11:06:15 CEST 2010
Mark Dickinson <dickinsm at gmail.com> added the comment:
Thinking about it a bit more, I really would prefer get_range_argument not to steal a reference. If I'm reading a bit of C code and encounter something like:
obj = transform(obj);
if (obj == NULL) ...
my hindbrain immediately starts fretting that something's wrong, and I have to go and ferret out the definition of 'transform' to be sure. In contrast, patterns like:
temp = transform(obj);
Py_DECREF(obj);
obj = temp;
if (obj == NULL) ...
are so common and familiar in the Python codebase that they don't raise the same sort of red flag.
----------
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue1533>
_______________________________________
More information about the Python-bugs-list
mailing list