Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
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
57 changes: 57 additions & 0 deletions Doc/c-api/frame.rst
Original file line number Diff line number Diff line change
Expand Up @@ -250,3 +250,60 @@ Unless using :pep:`523`, you will not need this.
.. versionadded:: 3.12


.. c:type:: PyUnstable_ExecutableKinds

An array of executable kinds (executor types) for frames, used for internal
debugging and tracing.

Tools like debuggers and profilers can use this to identify the type of execution
context associated with a frame (e.g. to filter out internal frames).
The entries are indexed by the following constants:

.. list-table::
:header-rows: 1
:widths: auto

* - Constant
- Description
* - :c:macro:`PyUnstable_EXECUTABLE_KIND_SKIP`
- The frame is internal (e.g. inlined) and should be skipped by tools.
* - :c:macro:`PyUnstable_EXECUTABLE_KIND_PY_FUNCTION`
- The frame corresponds to a standard Python function.

.. versionadded:: 3.13


.. c:macro:: PyUnstable_EXECUTABLE_KIND_SKIP

Index for the "skip" kind in :c:data:`PyUnstable_ExecutableKinds`.
Indicates that the frame's code object should be skipped.

.. versionadded:: 3.13


.. c:macro:: PyUnstable_EXECUTABLE_KIND_PY_FUNCTION

Index for the "Python function" kind in ``PyUnstable_ExecutableKinds``.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These should be links via :c:data:`PyUnstable_ExecutableKinds`


.. versionadded:: 3.13


.. c:macro:: PyUnstable_EXECUTABLE_KIND_BUILTIN_FUNCTION

Index for the "built-in function" kind in ``PyUnstable_ExecutableKinds``.

.. versionadded:: 3.13


.. c:macro:: PyUnstable_EXECUTABLE_KIND_METHOD_DESCRIPTOR

Index for the "method descriptor" kind in ``PyUnstable_ExecutableKinds``.

.. versionadded:: 3.13


.. c:macro:: PyUnstable_EXECUTABLE_KINDS

The number of entries in ``PyUnstable_ExecutableKinds``.

.. versionadded:: 3.13
6 changes: 0 additions & 6 deletions Tools/check-c-api-docs/ignored_c_api.txt
Original file line number Diff line number Diff line change
Expand Up @@ -80,12 +80,6 @@ PyLong_MASK
PyLong_SHIFT
# cpython/pyerrors.h
PyException_HEAD
# cpython/pyframe.h
PyUnstable_EXECUTABLE_KINDS
PyUnstable_EXECUTABLE_KIND_BUILTIN_FUNCTION
PyUnstable_EXECUTABLE_KIND_METHOD_DESCRIPTOR
PyUnstable_EXECUTABLE_KIND_PY_FUNCTION
PyUnstable_EXECUTABLE_KIND_SKIP
# cpython/pylifecycle.h
Py_FrozenMain
# cpython/unicodeobject.h
Expand Down
Loading