diff options
-rw-r--r-- | Lib/python/pyinit.swg | 16 | ||||
-rw-r--r-- | Lib/python/pyrun.swg | 6 |
2 files changed, 16 insertions, 6 deletions
diff --git a/Lib/python/pyinit.swg b/Lib/python/pyinit.swg index f5be6d599..dfbf40b34 100644 --- a/Lib/python/pyinit.swg +++ b/Lib/python/pyinit.swg @@ -8,6 +8,22 @@ %fragment("<stddef.h>"); // For offsetof #endif +%insert(runtime) %{ +#ifdef __cplusplus +extern "C" { +#endif + +/* Method creation and docstring support functions */ + +SWIGINTERN PyMethodDef *SWIG_PythonGetProxyDoc(const char *name); +SWIGINTERN PyObject *SWIG_PyInstanceMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func); +SWIGINTERN PyObject *SWIG_PyStaticMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func); + +#ifdef __cplusplus +} +#endif +%} + %init %{ #ifdef __cplusplus diff --git a/Lib/python/pyrun.swg b/Lib/python/pyrun.swg index 693cd6d46..ad1b81963 100644 --- a/Lib/python/pyrun.swg +++ b/Lib/python/pyrun.swg @@ -213,12 +213,6 @@ SWIG_Python_UnpackTuple(PyObject *args, const char *name, Py_ssize_t min, Py_ssi extern "C" { #endif -/* Method creation and docstring support functions */ - -SWIGINTERN PyMethodDef *SWIG_PythonGetProxyDoc(const char *name); -SWIGINTERN PyObject *SWIG_PyInstanceMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func); -SWIGINTERN PyObject *SWIG_PyStaticMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func); - /* The python void return value */ SWIGRUNTIMEINLINE PyObject * |