Skip to content

Commit 57a4052

Browse files
wjakobCAM-Gerlacherlend-aasland
authored
gh-98586: Add What's New entry and update docs (#99056)
Co-authored-by: C.A.M. Gerlach <[email protected]> Co-authored-by: Erlend E. Aasland <[email protected]>
1 parent bd221c0 commit 57a4052

File tree

3 files changed

+14
-2
lines changed

3 files changed

+14
-2
lines changed

Doc/c-api/call.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ This is a pointer to a function with the following signature:
9393
and they must be unique.
9494
If there are no keyword arguments, then *kwnames* can instead be *NULL*.
9595

96-
.. c:macro:: PY_VECTORCALL_ARGUMENTS_OFFSET
96+
.. data:: PY_VECTORCALL_ARGUMENTS_OFFSET
9797

9898
If this flag is set in a vectorcall *nargsf* argument, the callee is allowed
9999
to temporarily change ``args[-1]``. In other words, *args* points to

Doc/whatsnew/3.12.rst

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -677,6 +677,18 @@ New Features
677677
``__dict__`` and weakrefs with less bookkeeping,
678678
using less memory and with faster access.
679679

680+
* API for performing calls using
681+
:ref:`the vectorcall protocol <vectorcall>` was added to the
682+
:ref:`Limited API <stable>`:
683+
684+
* :c:func:`PyObject_Vectorcall`
685+
* :c:func:`PyObject_VectorcallMethod`
686+
* :const:`PY_VECTORCALL_ARGUMENTS_OFFSET`
687+
688+
This means that both the incoming and outgoing ends of the vector call
689+
protocol are now available in the :ref:`Limited API <stable>`. (Contributed
690+
by Wenzel Jakob in :gh:`98586`.)
691+
680692
* Added two new public functions,
681693
:c:func:`PyEval_SetProfileAllThreads` and
682694
:c:func:`PyEval_SetTraceAllThreads`, that allow to set tracing and profiling

Misc/NEWS.d/next/Core and Builtins/2022-10-24-10-30-30.gh-issue-98586.Tha5Iy.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Added the methods :c:func:`PyObject_Vectorcall` and
22
:c:func:`PyObject_VectorcallMethod` to the :ref:`Limited API <stable>` along
3-
with the auxiliary macro constant :c:macro:`PY_VECTORCALL_ARGUMENTS_OFFSET`.
3+
with the auxiliary macro constant :const:`PY_VECTORCALL_ARGUMENTS_OFFSET`.
44

55
The availability of these functions enables more efficient :PEP:`590` vector
66
calls from binary extension modules that avoid argument boxing/unboxing

0 commit comments

Comments
 (0)