Commit d9a9663b authored by Stefan Behnel's avatar Stefan Behnel

minor pypy code improvements

parent 9d45f84a
......@@ -29,7 +29,7 @@ static PyObject* __Pyx_Globals(void) {
goto bad;
for (i = PyList_GET_SIZE(names)-1; i >= 0; i--) {
#if CYTHON_COMPILING_IN_PYPY
PyObject* name = PySequence_GetItem(names, i);
PyObject* name = PySequence_ITEM(names, i);
if (!name)
goto bad;
#else
......
......@@ -545,7 +545,7 @@ static int __Pyx_PyUnicode_Tailmatch(PyObject* s, PyObject* substr,
result = PyUnicode_Tailmatch(s, PyTuple_GET_ITEM(substr, i),
start, end, direction);
#else
PyObject* sub = PySequence_GetItem(substr, i);
PyObject* sub = PySequence_ITEM(substr, i);
if (unlikely(!sub)) return -1;
result = PyUnicode_Tailmatch(s, sub, start, end, direction);
Py_DECREF(sub);
......@@ -630,7 +630,7 @@ static int __Pyx_PyBytes_Tailmatch(PyObject* self, PyObject* substr, Py_ssize_t
result = __Pyx_PyBytes_SingleTailmatch(self, PyTuple_GET_ITEM(substr, i),
start, end, direction);
#else
PyObject* sub = PySequence_GetItem(substr, i);
PyObject* sub = PySequence_ITEM(substr, i);
if (unlikely(!sub)) return -1;
result = __Pyx_PyBytes_SingleTailmatch(self, sub, start, end, direction);
Py_DECREF(sub);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment