diff options
Diffstat (limited to 'Python/bltinmodule.c')
-rw-r--r-- | Python/bltinmodule.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Python/bltinmodule.c b/Python/bltinmodule.c index a846377ec6..cf47c30889 100644 --- a/Python/bltinmodule.c +++ b/Python/bltinmodule.c @@ -144,6 +144,11 @@ builtin_apply(PyObject *self, PyObject *args) PyObject *func, *alist = NULL, *kwdict = NULL; PyObject *t = NULL, *retval = NULL; + if (Py_Py3kWarningFlag && + PyErr_Warn(PyExc_DeprecationWarning, + "apply() not supported in 3.x") < 0) + return NULL; + if (!PyArg_UnpackTuple(args, "apply", 1, 3, &func, &alist, &kwdict)) return NULL; if (alist != NULL) { |