gh-105107: Remove PyCFunction_Call() function (#105181)

* Keep the function in the stable ABI.
* Add unit tests on PyCFunction_Call() since it remains supported in
  the stable ABI.
This commit is contained in:
Victor Stinner 2023-06-01 11:25:55 +02:00 committed by GitHub
parent 7f5afecfd7
commit 27f9491c60
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 40 additions and 6 deletions

View file

@ -380,11 +380,11 @@ PyObject_Call(PyObject *callable, PyObject *args, PyObject *kwargs)
}
PyObject *
/* Function removed in the Python 3.13 API but kept in the stable ABI. */
PyAPI_FUNC(PyObject *)
PyCFunction_Call(PyObject *callable, PyObject *args, PyObject *kwargs)
{
PyThreadState *tstate = _PyThreadState_GET();
return _PyObject_Call(tstate, callable, args, kwargs);
return PyObject_Call(callable, args, kwargs);
}