Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions development-tools/clinic.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1495,6 +1495,27 @@ You can still use a self converter, a return converter, and specify
a *type* argument to the object converter for :c:macro:`METH_O`.


How to convert var-positional parameter functions
-------------------------------------------------

To convert a var-positional parameter function,
prepending the parameter name with ``*`` ,
and the parameter should use the ``object`` converter::
Comment thread
skirpichev marked this conversation as resolved.
Outdated

/*[clinic input]
var_positional_sample

foo: int
*args: object
Comment thread
AA-Turner marked this conversation as resolved.
Outdated
Comment thread
skirpichev marked this conversation as resolved.
Outdated
[clinic start generated code]*/

The implementation function will receive var-positional arguments
as *args* array.

.. versionadded:: 3.11
.. versionchanged:: 3.14
Comment thread
AA-Turner marked this conversation as resolved.
Outdated


How to convert ``tp_new`` and ``tp_init`` functions
---------------------------------------------------

Expand Down
Loading