Commit 8f445d7d authored by Stefan Behnel's avatar Stefan Behnel

PyPy does not support PyType_GetSlot(). Use type slots instead.

parent 8830bf2b
......@@ -343,7 +343,7 @@ __PYX_GOOD:
static CYTHON_INLINE PyObject *{{func_name}}_maybe_call_slot(PyTypeObject* type, PyObject *left, PyObject *right {{extra_arg_decl}}) {
{{slot_type}} slot;
#if CYTHON_USE_TYPE_SLOTS || PY_MAJOR_VERSION < 3
#if CYTHON_USE_TYPE_SLOTS || PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
slot = type->tp_as_number ? type->tp_as_number->{{slot_name}} : NULL;
#else
slot = ({{slot_type}}) PyType_GetSlot(type, Py_{{slot_name}});
......
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