mirror of https://github.com/python/cpython
bpo-39737: Remove code repitition in list_richcompare (GH-18638)
I may speed up list comparison on some platforms.
This commit is contained in:
parent
57c7a0bdf4
commit
be7ead62db
|
@ -2643,8 +2643,7 @@ list_richcompare(PyObject *v, PyObject *w, int op)
|
|||
|
||||
Py_INCREF(vitem);
|
||||
Py_INCREF(witem);
|
||||
int k = PyObject_RichCompareBool(vl->ob_item[i],
|
||||
wl->ob_item[i], Py_EQ);
|
||||
int k = PyObject_RichCompareBool(vitem, witem, Py_EQ);
|
||||
Py_DECREF(vitem);
|
||||
Py_DECREF(witem);
|
||||
if (k < 0)
|
||||
|
|
Loading…
Reference in New Issue