提交 fc6096c8 authored 作者: John Salvatier's avatar John Salvatier

fixed syntax error

上级 d3d6712f
...@@ -208,7 +208,9 @@ fail: ...@@ -208,7 +208,9 @@ fail:
"increments a numpy array inplace at the passed indexes."}, "increments a numpy array inplace at the passed indexes."},
#endif #endif
{NULL, NULL, 0, NULL} /* Sentinel */ {NULL, NULL, 0, NULL} /* Sentinel */
};""" };""")
if PY3: if PY3:
# This is not the most efficient code, but it is written this way to highlight # This is not the most efficient code, but it is written this way to highlight
# the changes needed to make 2.x code compile under python 3. # the changes needed to make 2.x code compile under python 3.
...@@ -228,7 +230,7 @@ fail: ...@@ -228,7 +230,7 @@ fail:
return PyModule_Create(&moduledef); return PyModule_Create(&moduledef);
} }
} }
""" """
else: else:
code += """ code += """
PyMODINIT_FUNC PyMODINIT_FUNC
...@@ -238,7 +240,7 @@ fail: ...@@ -238,7 +240,7 @@ fail:
(void) Py_InitModule("cutils_ext", CutilsExtMethods); (void) Py_InitModule("cutils_ext", CutilsExtMethods);
} }
} //extern C } //extern C
""") """
import cmodule import cmodule
loc = os.path.join(config.compiledir, 'cutils_ext') loc = os.path.join(config.compiledir, 'cutils_ext')
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论