Merged revisions 80758 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r80758 | mark.dickinson | 2010-05-04 17:18:25 +0100 (Tue, 04 May 2010) | 9 lines
Issue #1533: fix inconsistency in range function argument processing:
any non-float non-integer argument is now converted to an integer (if
possible) using its __int__ method. Previously, only small arguments
were treated this way; larger arguments (those whose __int__ was
outside the range of a C long) would produce a TypeError.
Patch by Alexander Belopolsky (with minor modifications).
........
diff --git a/Misc/NEWS b/Misc/NEWS
index 8e33eb9..944f804 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -12,6 +12,12 @@
Core and Builtins
-----------------
+- Issue #1533: fix inconsistency in range function argument
+ processing: any non-float non-integer argument is now converted to
+ an integer (if possible) using its __int__ method. Previously, only
+ small arguments were treated this way; larger arguments (those whose
+ __int__ was outside the range of a C long) would produce a TypeError.
+
- Issue #8417: Raise an OverflowError when an integer larger than sys.maxsize is
passed to bytearray.