summaryrefslogtreecommitdiffstats
path: root/Objects/rangeobject.c
diff options
context:
space:
mode:
Diffstat (limited to 'Objects/rangeobject.c')
-rw-r--r--Objects/rangeobject.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/Objects/rangeobject.c b/Objects/rangeobject.c
index a848d67..5d583b2 100644
--- a/Objects/rangeobject.c
+++ b/Objects/rangeobject.c
@@ -21,8 +21,6 @@ typedef struct {
PyObject *length;
} rangeobject;
-_Py_IDENTIFIER(iter);
-
/* Helper function for validating step. Always returns a new reference or
NULL on error.
*/
@@ -813,8 +811,8 @@ rangeiter_reduce(rangeiterobject *r, PyObject *Py_UNUSED(ignored))
if (range == NULL)
goto err;
/* return the result */
- return Py_BuildValue("N(N)l", _PyEval_GetBuiltinId(&PyId_iter),
- range, r->index);
+ return Py_BuildValue(
+ "N(N)l", _PyEval_GetBuiltin(&_Py_ID(iter)), range, r->index);
err:
Py_XDECREF(start);
Py_XDECREF(stop);
@@ -967,8 +965,8 @@ longrangeiter_reduce(longrangeiterobject *r, PyObject *Py_UNUSED(ignored))
}
/* return the result */
- return Py_BuildValue("N(N)O", _PyEval_GetBuiltinId(&PyId_iter),
- range, r->index);
+ return Py_BuildValue(
+ "N(N)O", _PyEval_GetBuiltin(&_Py_ID(iter)), range, r->index);
}
static PyObject *