mirror of
https://github.com/python/cpython.git
synced 2025-08-23 10:16:01 +00:00
gh-114626: add PyCFunctionFast and PyCFunctionFastWithKeywords (GH-114627)
Co-authored-by: Petr Viktorin <encukou@gmail.com>
This commit is contained in:
parent
32f8ab1ab6
commit
9e3729bbd7
10 changed files with 57 additions and 41 deletions
|
@ -417,7 +417,7 @@ cfunction_vectorcall_FASTCALL(
|
|||
return NULL;
|
||||
}
|
||||
Py_ssize_t nargs = PyVectorcall_NARGS(nargsf);
|
||||
_PyCFunctionFast meth = (_PyCFunctionFast)
|
||||
PyCFunctionFast meth = (PyCFunctionFast)
|
||||
cfunction_enter_call(tstate, func);
|
||||
if (meth == NULL) {
|
||||
return NULL;
|
||||
|
@ -433,7 +433,7 @@ cfunction_vectorcall_FASTCALL_KEYWORDS(
|
|||
{
|
||||
PyThreadState *tstate = _PyThreadState_GET();
|
||||
Py_ssize_t nargs = PyVectorcall_NARGS(nargsf);
|
||||
_PyCFunctionFastWithKeywords meth = (_PyCFunctionFastWithKeywords)
|
||||
PyCFunctionFastWithKeywords meth = (PyCFunctionFastWithKeywords)
|
||||
cfunction_enter_call(tstate, func);
|
||||
if (meth == NULL) {
|
||||
return NULL;
|
||||
|
@ -552,4 +552,3 @@ cfunction_call(PyObject *func, PyObject *args, PyObject *kwargs)
|
|||
}
|
||||
return _Py_CheckFunctionResult(tstate, func, result, NULL);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue