mirror of
https://github.com/python/cpython.git
synced 2025-09-25 09:50:37 +00:00
Fix the names of the classmethod and staticmethod constructors as passed to
PyArg_ParseTuple() as part of the format string.
This commit is contained in:
parent
a2bd8d3816
commit
cd874edaaa
1 changed files with 2 additions and 2 deletions
|
@ -486,7 +486,7 @@ cm_init(PyObject *self, PyObject *args, PyObject *kwds)
|
||||||
classmethod *cm = (classmethod *)self;
|
classmethod *cm = (classmethod *)self;
|
||||||
PyObject *callable;
|
PyObject *callable;
|
||||||
|
|
||||||
if (!PyArg_ParseTuple(args, "O:callable", &callable))
|
if (!PyArg_ParseTuple(args, "O:classmethod", &callable))
|
||||||
return -1;
|
return -1;
|
||||||
Py_INCREF(callable);
|
Py_INCREF(callable);
|
||||||
cm->cm_callable = callable;
|
cm->cm_callable = callable;
|
||||||
|
@ -618,7 +618,7 @@ sm_init(PyObject *self, PyObject *args, PyObject *kwds)
|
||||||
staticmethod *sm = (staticmethod *)self;
|
staticmethod *sm = (staticmethod *)self;
|
||||||
PyObject *callable;
|
PyObject *callable;
|
||||||
|
|
||||||
if (!PyArg_ParseTuple(args, "O:callable", &callable))
|
if (!PyArg_ParseTuple(args, "O:staticmethod", &callable))
|
||||||
return -1;
|
return -1;
|
||||||
Py_INCREF(callable);
|
Py_INCREF(callable);
|
||||||
sm->sm_callable = callable;
|
sm->sm_callable = callable;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue