Skip to content

Commit

Permalink
PEP 590: rename PyCall_MakeVectorCall -> PyVectorcall_Call (GH-1037)
Browse files Browse the repository at this point in the history
  • Loading branch information
jdemeyer authored and encukou committed May 12, 2019
1 parent 468ab6e commit 1df4f57
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pep-0590.rst
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ The following functions or macros are added to the C API:
This uses either the vectorcall protocol or ``tp_call`` internally;
if neither is supported, an exception is raised.

- ``PyObject *PyCall_MakeVectorCall(PyObject *obj, PyObject *tuple, PyObject *dict)``:
- ``PyObject *PyVectorcall_Call(PyObject *obj, PyObject *tuple, PyObject *dict)``:
Call the object (which must support vectorcall) with the old
``*args`` and ``**kwargs`` calling convention.
This is mostly meant to put in the ``tp_call`` slot.
Expand Down Expand Up @@ -216,7 +216,7 @@ To enable call performance on a par with Python functions and built-in functions
third-party callables should include a ``vectorcallfunc`` function pointer,
set ``tp_vectorcall_offset`` to the correct value and add the ``Py_TPFLAGS_HAVE_VECTORCALL`` flag.
Any class that does this must implement the ``tp_call`` function and make sure its behaviour is consistent with the ``vectorcallfunc`` function.
Setting ``tp_call`` to ``PyCall_MakeVectorCall`` is sufficient.
Setting ``tp_call`` to ``PyVectorcall_Call`` is sufficient.


Performance implications of these changes
Expand Down

0 comments on commit 1df4f57

Please sign in to comment.