Kaydet (Commit) 3e59076b authored tarafından Neal Norwitz's avatar Neal Norwitz

Fix SF bug #690435, apply fails to check if warning raises exception

(patch provided by Greg Chapman)
üst 7aba3d47
......@@ -75,9 +75,10 @@ builtin_apply(PyObject *self, PyObject *args)
PyObject *func, *alist = NULL, *kwdict = NULL;
PyObject *t = NULL, *retval = NULL;
PyErr_Warn(PyExc_PendingDeprecationWarning,
"use func(*args, **kwargs) instead of "
"apply(func, args, kwargs)");
if (PyErr_Warn(PyExc_PendingDeprecationWarning,
"use func(*args, **kwargs) instead of "
"apply(func, args, kwargs)") < 0)
return NULL;
if (!PyArg_UnpackTuple(args, "apply", 1, 3, &func, &alist, &kwdict))
return NULL;
if (alist != NULL) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment