Commit 3f00ce37 authored by Max Bachmann's avatar Max Bachmann Committed by GitHub

Do not use PyImport_GetModule() in older PyPy versions that do not have it (GH-4055)

parent f7320e37
...@@ -58,7 +58,7 @@ bad: ...@@ -58,7 +58,7 @@ bad:
#if PY_MAJOR_VERSION >= 3 #if PY_MAJOR_VERSION >= 3
static PyObject *__Pyx__ImportDottedModule_Lookup(PyObject *name) { static PyObject *__Pyx__ImportDottedModule_Lookup(PyObject *name) {
PyObject *imported_module; PyObject *imported_module;
#if PY_VERSION_HEX < 0x030700A1 #if PY_VERSION_HEX < 0x030700A1 || (CYTHON_COMPILING_IN_PYPY && PYPY_VERSION_NUM < 0x07030400)
PyObject *modules = PyImport_GetModuleDict(); PyObject *modules = PyImport_GetModuleDict();
if (unlikely(!modules)) if (unlikely(!modules))
return NULL; return NULL;
......
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