]> granicus.if.org Git - python/commitdiff
Issue #8276: PyEval_CallObject() is now only available in macro form. The
authorAntoine Pitrou <solipsis@pitrou.net>
Thu, 1 Apr 2010 16:42:11 +0000 (16:42 +0000)
committerAntoine Pitrou <solipsis@pitrou.net>
Thu, 1 Apr 2010 16:42:11 +0000 (16:42 +0000)
function declaration, which was kept for backwards compatibility reasons,
is now removed (the macro was introduced in 1997!).

Include/ceval.h
Misc/NEWS
Python/ceval.c

index f4411977fb1da5b341f27de09cd2f41e53d8d560..a3b3dcfc6f0a62d6973c2aed8d360678824d66fd 100644 (file)
@@ -10,10 +10,6 @@ extern "C" {
 PyAPI_FUNC(PyObject *) PyEval_CallObjectWithKeywords(
        PyObject *, PyObject *, PyObject *);
 
-/* DLL-level Backwards compatibility: */
-#undef PyEval_CallObject
-PyAPI_FUNC(PyObject *) PyEval_CallObject(PyObject *, PyObject *);
-
 /* Inline this */
 #define PyEval_CallObject(func,arg) \
         PyEval_CallObjectWithKeywords(func, arg, (PyObject *)NULL)
index ec2da1e2d7cb11ecb88c806e34ddd4da4a22739a..3715520cf065cbd20650bad9fa4fe0874a3868d7 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -169,6 +169,10 @@ Build
 C-API
 -----
 
+- Issue #8276: PyEval_CallObject() is now only available in macro form.  The
+  function declaration, which was kept for backwards compatibility reasons,
+  is now removed (the macro was introduced in 1997!).
+
 - Issue #7992: A replacement PyCObject API, PyCapsule, has been backported
   from Python 3.1.
 
index 339a35163659b7fe946ea7b0462569fceaf80333..b06de50d22c06b09a4978748f0505db0ca40ed26 100644 (file)
@@ -3852,18 +3852,7 @@ Py_FlushLine(void)
 
 
 /* External interface to call any callable object.
-   The arg must be a tuple or NULL. */
-
-#undef PyEval_CallObject
-/* for backward compatibility: export this interface */
-
-PyObject *
-PyEval_CallObject(PyObject *func, PyObject *arg)
-{
-       return PyEval_CallObjectWithKeywords(func, arg, (PyObject *)NULL);
-}
-#define PyEval_CallObject(func,arg) \
-        PyEval_CallObjectWithKeywords(func, arg, (PyObject *)NULL)
+   The arg must be a tuple or NULL.  The kw must be a dict or NULL. */
 
 PyObject *
 PyEval_CallObjectWithKeywords(PyObject *func, PyObject *arg, PyObject *kw)