diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2016-08-22 20:48:54 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2016-08-22 20:48:54 (GMT) |
commit | 559bb6a71399af3b1b2a0ba97230d2bcc649e993 (patch) | |
tree | 94927374ac025ae249aa487ce4a17df99c3df2d8 /Modules | |
parent | c98afb7a26ac611a4544c5b8dd445d8ea05e6360 (diff) | |
download | cpython-559bb6a71399af3b1b2a0ba97230d2bcc649e993.zip cpython-559bb6a71399af3b1b2a0ba97230d2bcc649e993.tar.gz cpython-559bb6a71399af3b1b2a0ba97230d2bcc649e993.tar.bz2 |
Rename _PyObject_FastCall() to _PyObject_FastCallDict()
Issue #27809:
* Rename _PyObject_FastCall() function to _PyObject_FastCallDict()
* Add _PyObject_FastCall(), _PyObject_CallNoArg() and _PyObject_CallArg1()
macros calling _PyObject_FastCallDict()
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/_elementtree.c | 2 | ||||
-rw-r--r-- | Modules/_functoolsmodule.c | 2 | ||||
-rw-r--r-- | Modules/_pickle.c | 6 | ||||
-rw-r--r-- | Modules/_sre.c | 2 |
4 files changed, 6 insertions, 6 deletions
diff --git a/Modules/_elementtree.c b/Modules/_elementtree.c index 5d124b3..721293a 100644 --- a/Modules/_elementtree.c +++ b/Modules/_elementtree.c @@ -858,7 +858,7 @@ deepcopy(PyObject *object, PyObject *memo) stack[0] = object; stack[1] = memo; - return _PyObject_FastCall(st->deepcopy_obj, stack, 2, NULL); + return _PyObject_FastCall(st->deepcopy_obj, stack, 2); } diff --git a/Modules/_functoolsmodule.c b/Modules/_functoolsmodule.c index f7dbf15..22e8088 100644 --- a/Modules/_functoolsmodule.c +++ b/Modules/_functoolsmodule.c @@ -492,7 +492,7 @@ keyobject_richcompare(PyObject *ko, PyObject *other, int op) */ stack[0] = x; stack[1] = y; - res = _PyObject_FastCall(compare, stack, 2, NULL); + res = _PyObject_FastCall(compare, stack, 2); if (res == NULL) { return NULL; } diff --git a/Modules/_pickle.c b/Modules/_pickle.c index b454134..fed3fa2 100644 --- a/Modules/_pickle.c +++ b/Modules/_pickle.c @@ -357,7 +357,7 @@ _Pickle_FastCall(PyObject *func, PyObject *obj) significantly reduced the number of function calls we do. Thus, the benefits became marginal at best. */ - result = _PyObject_FastCall(func, &obj, 1, NULL); + result = _PyObject_CallArg1(func, obj); Py_DECREF(obj); return result; } @@ -1151,7 +1151,7 @@ _Unpickler_ReadFromFile(UnpicklerObject *self, Py_ssize_t n) return -1; if (n == READ_WHOLE_LINE) { - data = _PyObject_FastCall(self->readline, NULL, 0, NULL); + data = _PyObject_CallNoArg(self->readline); } else { PyObject *len; @@ -3948,7 +3948,7 @@ save(PicklerObject *self, PyObject *obj, int pers_save) /* Check for a __reduce__ method. */ reduce_func = _PyObject_GetAttrId(obj, &PyId___reduce__); if (reduce_func != NULL) { - reduce_value = _PyObject_FastCall(reduce_func, NULL, 0, NULL); + reduce_value = _PyObject_CallNoArg(reduce_func); } else { PyErr_Format(st->PicklingError, diff --git a/Modules/_sre.c b/Modules/_sre.c index 3e8d7f8..0a62f62 100644 --- a/Modules/_sre.c +++ b/Modules/_sre.c @@ -1157,7 +1157,7 @@ pattern_subx(PatternObject* self, PyObject* ptemplate, PyObject* string, match = pattern_new_match(self, &state, 1); if (!match) goto error; - item = _PyObject_FastCall(filter, &match, 1, NULL); + item = _PyObject_CallArg1(filter, match); Py_DECREF(match); if (!item) goto error; |