diff --git a/interfaces/pivy_common_typemaps.i b/interfaces/pivy_common_typemaps.i index 27e26a6..4933b85 100644 --- a/interfaces/pivy_common_typemaps.i +++ b/interfaces/pivy_common_typemaps.i @@ -29,7 +29,7 @@ typedef int Py_ssize_t; #endif PyObject * -cast_internal(PyObject * self, PyObject * obj, const char * type_name, int type_len) +cast_internal(PyObject * self, PyObject * obj, const char * type_name, Py_ssize_t type_len) { swig_type_info * swig_type = 0; void * cast_obj = 0; @@ -76,7 +76,7 @@ SWIGEXPORT PyObject * cast(PyObject * self, PyObject * args) { char * type_name; - int type_len; + Py_ssize_t type_len; PyObject * obj = 0; if (!PyArg_ParseTuple(args, "Os#:cast", &obj, &type_name, &type_len)) { diff --git a/interfaces/soqt.i b/interfaces/soqt.i index 13fb228..57d6942 100644 --- a/interfaces/soqt.i +++ b/interfaces/soqt.i @@ -23,6 +23,9 @@ otherwise it will fall back to regular SWIG structures." %module(package="pivy.gui", docstring=SOQT_MODULE_DOCSTRING) soqt +%begin %{ +#define PY_SSIZE_T_CLEAN +%} %{ /*