mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
bpo-29548: Fix some inefficient call API usage (GH-97)
This commit is contained in:
parent
72e81d00ee
commit
72dccde884
7 changed files with 23 additions and 40 deletions
|
@ -3070,7 +3070,7 @@ slot_tp_del(PyObject *self)
|
|||
/* Execute __del__ method, if any. */
|
||||
del = _PyObject_LookupSpecial(self, &PyId___tp_del__);
|
||||
if (del != NULL) {
|
||||
res = PyEval_CallObject(del, NULL);
|
||||
res = _PyObject_CallNoArg(del);
|
||||
if (res == NULL)
|
||||
PyErr_WriteUnraisable(del);
|
||||
else
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue