@@ -25,8 +25,7 @@ static PyObject * cfunction_vectorcall_FASTCALL_KEYWORDS_METHOD(
2525 PyObject * func , PyObject * const * args , size_t nargsf , PyObject * kwnames );
2626static PyObject * cfunction_vectorcall_NOARGS (
2727 PyObject * func , PyObject * const * args , size_t nargsf , PyObject * kwnames );
28- /* Non-static: used by static _PyBuiltin_All/_Any in bltinmodule.c. */
29- PyObject * _PyCFunction_vectorcall_O (
28+ static PyObject * cfunction_vectorcall_O (
3029 PyObject * func , PyObject * const * args , size_t nargsf , PyObject * kwnames );
3130static PyObject * cfunction_call (
3231 PyObject * func , PyObject * args , PyObject * kwargs );
@@ -68,7 +67,7 @@ PyCMethod_New(PyMethodDef *ml, PyObject *self, PyObject *module, PyTypeObject *c
6867 vectorcall = cfunction_vectorcall_NOARGS ;
6968 break ;
7069 case METH_O :
71- vectorcall = _PyCFunction_vectorcall_O ;
70+ vectorcall = cfunction_vectorcall_O ;
7271 break ;
7372 case METH_METHOD | METH_FASTCALL | METH_KEYWORDS :
7473 vectorcall = cfunction_vectorcall_FASTCALL_KEYWORDS_METHOD ;
@@ -353,12 +352,6 @@ meth_hash(PyObject *self)
353352 return x ;
354353}
355354
356- static int
357- cfunction_is_gc (PyObject * op )
358- {
359- return !_Py_IsStaticImmortal (op );
360- }
361-
362355
363356PyTypeObject PyCFunction_Type = {
364357 PyVarObject_HEAD_INIT (& PyType_Type , 0 )
@@ -394,7 +387,6 @@ PyTypeObject PyCFunction_Type = {
394387 meth_getsets , /* tp_getset */
395388 0 , /* tp_base */
396389 0 , /* tp_dict */
397- .tp_is_gc = cfunction_is_gc ,
398390};
399391
400392PyTypeObject PyCMethod_Type = {
@@ -519,8 +511,8 @@ cfunction_vectorcall_NOARGS(
519511 return result ;
520512}
521513
522- PyObject *
523- _PyCFunction_vectorcall_O (
514+ static PyObject *
515+ cfunction_vectorcall_O (
524516 PyObject * func , PyObject * const * args , size_t nargsf , PyObject * kwnames )
525517{
526518 PyThreadState * tstate = _PyThreadState_GET ();
0 commit comments