summaryrefslogtreecommitdiff
path: root/Cython/Compiler/ModuleNode.py
diff options
context:
space:
mode:
authorAnselm Kruis <Anselm.Kruis@atos.net>2018-08-14 12:46:46 +0200
committerAnselm Kruis <Anselm.Kruis@atos.net>2018-08-14 12:46:46 +0200
commitc1a6417489dfc9140cc64407fbcfa0684ba95ba1 (patch)
treea3e85e48b65c30edd8df4e9f844e5c2a67ba0991 /Cython/Compiler/ModuleNode.py
parent60d135b706d4cf6fb3abf74af227ada2cdd65fe8 (diff)
downloadcython-c1a6417489dfc9140cc64407fbcfa0684ba95ba1.tar.gz
make __Pyx_PyFunction_FastCallNoKw compatible with Stackless Python
Compute the offset of the PyFrameObject member "f_localsplus" at runtime, because the layout of PyFrameObject differs between regular C-python and Stackless Python.
Diffstat (limited to 'Cython/Compiler/ModuleNode.py')
-rw-r--r--Cython/Compiler/ModuleNode.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/Cython/Compiler/ModuleNode.py b/Cython/Compiler/ModuleNode.py
index 8a9186e01..5d41fe08c 100644
--- a/Cython/Compiler/ModuleNode.py
+++ b/Cython/Compiler/ModuleNode.py
@@ -2357,6 +2357,7 @@ class ModuleNode(Nodes.Node, Nodes.BlockNode):
env.use_utility_code(UtilityCode.load("CheckBinaryVersion", "ModuleSetupCode.c"))
code.put_error_if_neg(self.pos, "__Pyx_check_binary_version()")
+ code.putln("__Pxy_PyFrame_Initialize_Offsets();")
code.putln("%s = PyTuple_New(0); %s" % (
Naming.empty_tuple, code.error_goto_if_null(Naming.empty_tuple, self.pos)))
code.putln("%s = PyBytes_FromStringAndSize(\"\", 0); %s" % (