summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorR David Murray <rdmurray@bitdance.com>2014-02-10 21:30:42 -0500
committerR David Murray <rdmurray@bitdance.com>2014-02-10 21:30:42 -0500
commit04e24288e1b203280794795542a480277d19e820 (patch)
treec8f3f44c3e3109e22d8923028642b240826578db
parent8dffa0e5cf0640fe7f3ca2a4940f97889397f0a8 (diff)
downloadcpython-git-04e24288e1b203280794795542a480277d19e820.tar.gz
whatsnew: slice.index no longer accepts negative values (or overflows).
-rw-r--r--Doc/whatsnew/3.4.rst5
1 files changed, 5 insertions, 0 deletions
diff --git a/Doc/whatsnew/3.4.rst b/Doc/whatsnew/3.4.rst
index b1ef2775b2..8e028e6603 100644
--- a/Doc/whatsnew/3.4.rst
+++ b/Doc/whatsnew/3.4.rst
@@ -1720,6 +1720,11 @@ Changes in the Python API
informative :exc:`ValueError` rather than the previous more mysterious
:exc:`AttributeError` (:issue:`9177`).
+* :meth:`slice.indices` no longer produces an :exc:`OverflowError` for huge
+ values. As a consequence of this fix, :meth:`slice.indices` now raises a
+ :exc:`ValueError` if given a negative length; previously it returned nonsense
+ values (:issue:`14794`).
+
Changes in the C API
--------------------