gh-111178: Fix type of PyCMethod's "nargs" argument (GH-131135)

Replace "size_t nargs" with "Py_ssize_t nargs" in PyCMethod.
This commit is contained in:
Victor Stinner 2025-03-12 11:54:02 +01:00 committed by GitHub
parent e0637cebe5
commit 4dcbe06fd2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 3 additions and 1 deletions

View file

@ -24,7 +24,7 @@ typedef PyObject *(*PyCFunctionFastWithKeywords) (PyObject *,
PyObject *const *, Py_ssize_t,
PyObject *);
typedef PyObject *(*PyCMethod)(PyObject *, PyTypeObject *, PyObject *const *,
size_t, PyObject *);
Py_ssize_t, PyObject *);
// For backwards compatibility. `METH_FASTCALL` was added to the stable API in
// 3.10 alongside `_PyCFunctionFastWithKeywords` and `_PyCFunctionFast`.