From ad3f3321f6067b67f7b6d3fa1eb72abc335a02ed Mon Sep 17 00:00:00 2001 From: Raymond Hettinger Date: Sat, 9 Feb 2008 04:13:49 +0000 Subject: [PATCH] Merge r60673 --- Objects/rangeobject.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Objects/rangeobject.c b/Objects/rangeobject.c index dfd3cac1c7b..5ea5d6fb87d 100644 --- a/Objects/rangeobject.c +++ b/Objects/rangeobject.c @@ -220,7 +220,7 @@ range_item(rangeobject *r, Py_ssize_t i) } /* XXX(nnorwitz): optimize for short ints. */ - rem = PyLong_FromSsize_t(i % len); + rem = PyLong_FromSsize_t(i); if (!rem) return NULL; incr = PyNumber_Multiply(rem, r->step);