summaryrefslogtreecommitdiffstats
path: root/Include
diff options
context:
space:
mode:
authorMartin v. Löwis <martin@v.loewis.de>2006-04-14 09:08:42 (GMT)
committerMartin v. Löwis <martin@v.loewis.de>2006-04-14 09:08:42 (GMT)
commit5cb6936672a1410f5502d754570bc548064f9dc4 (patch)
tree16c2d4cecdd7441b642707a43ed37ce900197175 /Include
parent38a76a101796d43fb8cd6c6d5ba54bb811d06f49 (diff)
downloadcpython-5cb6936672a1410f5502d754570bc548064f9dc4.zip
cpython-5cb6936672a1410f5502d754570bc548064f9dc4.tar.gz
cpython-5cb6936672a1410f5502d754570bc548064f9dc4.tar.bz2
Make Py_BuildValue, PyObject_CallFunction and
PyObject_CallMethod aware of PY_SSIZE_T_CLEAN.
Diffstat (limited to 'Include')
-rw-r--r--Include/abstract.h5
-rw-r--r--Include/modsupport.h14
2 files changed, 7 insertions, 12 deletions
diff --git a/Include/abstract.h b/Include/abstract.h
index 9ec18fa..3dcc0b0 100644
--- a/Include/abstract.h
+++ b/Include/abstract.h
@@ -4,6 +4,11 @@
extern "C" {
#endif
+#ifdef PY_SSIZE_T_CLEAN
+#define PyObject_CallFunction _PyObject_CallFunction_SizeT
+#define PyObject_CallMethod _PyObject_CallMethod_SizeT
+#endif
+
/* Abstract Object Interface (many thanks to Jim Fulton) */
/*
diff --git a/Include/modsupport.h b/Include/modsupport.h
index 5471197..1141d6a 100644
--- a/Include/modsupport.h
+++ b/Include/modsupport.h
@@ -17,21 +17,11 @@ extern "C" {
#define PyArg_ParseTupleAndKeywords _PyArg_ParseTupleAndKeywords_SizeT
#define PyArg_VaParse _PyArg_VaParse_SizeT
#define PyArg_VaParseTupleAndKeywords _PyArg_VaParseTupleAndKeywords_SizeT
-#define PyArg_BuildValue _PyArg_BuildValue_SizeT
-#define PyArg_VaBuildValue _PyArg_VaBuildValue_SizeT
+#define Py_BuildValue _Py_BuildValue_SizeT
+#define Py_VaBuildValue _Py_VaBuildValue_SizeT
#else
-#ifdef HAVE_DECLSPEC_DLL
-PyAPI_FUNC(int) _PyArg_Parse_SizeT(PyObject *, char *, ...);
-PyAPI_FUNC(int) _PyArg_ParseTuple_SizeT(PyObject *, char *, ...);
-PyAPI_FUNC(int) _PyArg_ParseTupleAndKeywords_SizeT(PyObject *, PyObject *,
- const char *, char **, ...);
-PyAPI_FUNC(PyObject *) _Py_BuildValue_SizeT(const char *, ...);
-PyAPI_FUNC(int) _PyArg_VaParse_SizeT(PyObject *, char *, va_list);
-PyAPI_FUNC(int) _PyArg_VaParseTupleAndKeywords_SizeT(PyObject *, PyObject *,
- const char *, char **, va_list);
PyAPI_FUNC(PyObject *) _Py_VaBuildValue_SizeT(const char *, va_list);
#endif
-#endif
PyAPI_FUNC(int) PyArg_Parse(PyObject *, const char *, ...);
PyAPI_FUNC(int) PyArg_ParseTuple(PyObject *, const char *, ...);