8000 gh-111178: Make slot functions in typeobject.c have compatible types by chrstphrchvz · Pull Request #112752 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

gh-111178: Make slot functions in typeobject.c have compatible types #112752

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 10 commits into from
Dec 20, 2023
Prev Previous commit
Next Next commit
Make type_call() compatible with ternaryfunc
  • Loading branch information
chrstphrchvz authored Dec 5, 2023
commit e32433ce2293be671390e7f19c0af8221dba7928
5 changes: 3 additions & 2 deletions Objects/typeobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -1631,8 +1631,9 @@ type_repr(PyObject *self)
}

static PyObject *
type_call(PyTypeObject *type, PyObject *args, PyObject *kwds)
type_call(PyObject *self, PyObject *args, PyObject *kwds)
{
PyTypeObject *type = (PyTypeObject *)self;
PyObject *obj;
PyThreadState *tstate = _PyThreadState_GET();

Expand Down Expand Up @@ -5362,7 +5363,7 @@ PyTypeObject PyType_Type = {
0, /* tp_as_sequence */
0, /* tp_as_mapping */
0, /* tp_hash */
(ternaryfunc)type_call, /* tp_call */
type_call, /* tp_call */
0, /* tp_str */
(getattrofunc)_Py_type_getattro, /* tp_getattro */
(setattrofunc)type_setattro, /* tp_setattro */
Expand Down
0