diff options
Diffstat (limited to 'Objects/listobject.c')
-rw-r--r-- | Objects/listobject.c | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/Objects/listobject.c b/Objects/listobject.c index 79403cc..75ad235 100644 --- a/Objects/listobject.c +++ b/Objects/listobject.c @@ -2398,14 +2398,6 @@ listiter_traverse(listiterobject *it, visitproc visit, void *arg) return visit((PyObject *)it->it_seq, arg); } - -static PyObject * -listiter_getiter(PyObject *it) -{ - Py_INCREF(it); - return it; -} - static PyObject * listiter_next(listiterobject *it) { @@ -2458,7 +2450,7 @@ PyTypeObject PyListIter_Type = { 0, /* tp_clear */ 0, /* tp_richcompare */ 0, /* tp_weaklistoffset */ - (getiterfunc)listiter_getiter, /* tp_iter */ + PyObject_GenericGetIter, /* tp_iter */ (iternextfunc)listiter_next, /* tp_iternext */ 0, /* tp_methods */ 0, /* tp_members */ |