summaryrefslogtreecommitdiffstats
path: root/Objects
diff options
context:
space:
mode:
authorAntoine Pitrou <solipsis@pitrou.net>2012-05-16 12:39:36 (GMT)
committerAntoine Pitrou <solipsis@pitrou.net>2012-05-16 12:39:36 (GMT)
commitb7d033db783b8ca2e4dfe23e348129ed666b6e2b (patch)
tree4c504d15647a3997d62e8e2da43dc16d5a2791da /Objects
parentb84bc7a7ce6649f786b5b3f80e944cb51b332faf (diff)
parenta103b96a80f049f68ccf2dd3d5d7858b26a27e94 (diff)
downloadcpython-b7d033db783b8ca2e4dfe23e348129ed666b6e2b.zip
cpython-b7d033db783b8ca2e4dfe23e348129ed666b6e2b.tar.gz
cpython-b7d033db783b8ca2e4dfe23e348129ed666b6e2b.tar.bz2
Issue #14829: Fix bisect and range() indexing with large indices (>= 2 ** 32) under 64-bit Windows.
(untested, because of Windows build issues under 3.x)
Diffstat (limited to 'Objects')
-rw-r--r--Objects/rangeobject.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/rangeobject.c b/Objects/rangeobject.c
index 99544d6..c47a4ff 100644
--- a/Objects/rangeobject.c
+++ b/Objects/rangeobject.c
@@ -308,7 +308,7 @@ compute_range_item(rangeobject *r, PyObject *arg)
static PyObject *
range_item(rangeobject *r, Py_ssize_t i)
{
- PyObject *res, *arg = PyLong_FromLong(i);
+ PyObject *res, *arg = PyLong_FromSsize_t(i);
if (!arg) {
return NULL;
}