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
Prev Previous commit
Next Next commit
Make necessary changes in a documentation
  • Loading branch information
wrongnull committed Feb 22, 2024
commit 001fe51234cf6d8662f1c92c11479a7540ccc6c4
8 changes: 7 additions & 1 deletion Doc/c-api/code.rst
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,16 @@ bound into a function.

Return the number of free variables in a code object.

.. c:function:: int PyCode_GetFirstFree(PyCodeObject *co)
.. c:function:: int PyUnstable_Code_GetFirstFree(PyCodeObject *co)

Return the position of the first free variable in a code object.

.. versionchanged:: 3.13

Renamed from ``PyCode_GetFirstFree`` as part of :ref:`unstable-c-api`.
The old name is deprecated, but will remain available until the
signature changes again.

.. c:function:: PyCodeObject* PyUnstable_Code_New(int argcount, int kwonlyargcount, int nlocals, int stacksize, int flags, PyObject *code, PyObject *consts, PyObject *names, PyObject *varnames, PyObject *freevars, PyObject *cellvars, PyObject *filename, PyObject *name, PyObject *qualname, int firstlineno, PyObject *linetable, PyObject *exceptiontable)

Return a new code object. If you need a dummy code object to create a frame,
Expand Down