@@ -813,14 +813,14 @@ _parse_object_unicode(PyScannerObject *s, PyObject *pystr, Py_ssize_t idx, Py_ss
813813 * next_idx_ptr = idx + 1 ;
814814
815815 if (has_pairs_hook ) {
816- val = _PyObject_CallArg1 (s -> object_pairs_hook , rval );
816+ val = PyObject_CallFunctionObjArgs (s -> object_pairs_hook , rval , NULL );
817817 Py_DECREF (rval );
818818 return val ;
819819 }
820820
821821 /* if object_hook is not None: rval = object_hook(rval) */
822822 if (s -> object_hook != Py_None ) {
823- val = _PyObject_CallArg1 (s -> object_hook , rval );
823+ val = PyObject_CallFunctionObjArgs (s -> object_hook , rval , NULL );
824824 Py_DECREF (rval );
825825 return val ;
826826 }
@@ -924,7 +924,7 @@ _parse_constant(PyScannerObject *s, const char *constant, Py_ssize_t idx, Py_ssi
924924 return NULL ;
925925
926926 /* rval = parse_constant(constant) */
927- rval = _PyObject_CallArg1 (s -> parse_constant , cstr );
927+ rval = PyObject_CallFunctionObjArgs (s -> parse_constant , cstr , NULL );
928928 idx += PyUnicode_GET_LENGTH (cstr );
929929 Py_DECREF (cstr );
930930 * next_idx_ptr = idx ;
@@ -1023,7 +1023,7 @@ _match_number_unicode(PyScannerObject *s, PyObject *pystr, Py_ssize_t start, Py_
10231023 idx - start );
10241024 if (numstr == NULL )
10251025 return NULL ;
1026- rval = _PyObject_CallArg1 (custom_func , numstr );
1026+ rval = PyObject_CallFunctionObjArgs (custom_func , numstr , NULL );
10271027 }
10281028 else {
10291029 Py_ssize_t i , n ;
@@ -1475,7 +1475,7 @@ encoder_encode_string(PyEncoderObject *s, PyObject *obj)
14751475 if (s -> fast_encode )
14761476 return s -> fast_encode (NULL , obj );
14771477 else
1478- return _PyObject_CallArg1 (s -> encoder , obj );
1478+ return PyObject_CallFunctionObjArgs (s -> encoder , obj , NULL );
14791479}
14801480
14811481static int
@@ -1553,7 +1553,7 @@ encoder_listencode_obj(PyEncoderObject *s, _PyAccu *acc,
15531553 return -1 ;
15541554 }
15551555 }
1556- newobj = _PyObject_CallArg1 (s -> defaultfn , obj );
1556+ newobj = PyObject_CallFunctionObjArgs (s -> defaultfn , obj , NULL );
15571557 if (newobj == NULL ) {
15581558 Py_XDECREF (ident );
15591559 return -1 ;
0 commit comments