mirror of
https://github.com/python/cpython.git
synced 2025-12-23 09:19:18 +00:00
gh-141004: Document Py_MakePendingCalls (GH-141137)
Co-authored-by: Victor Stinner <vstinner@python.org>
This commit is contained in:
parent
41b9ad5b38
commit
ce701032a3
1 changed files with 19 additions and 0 deletions
|
|
@ -1891,6 +1891,25 @@ pointer and a void pointer argument.
|
|||
This function now always schedules *func* to be run in the main
|
||||
interpreter.
|
||||
|
||||
|
||||
.. c:function:: int Py_MakePendingCalls(void)
|
||||
|
||||
Execute all pending calls. This is usually executed automatically by the
|
||||
interpreter.
|
||||
|
||||
This function returns ``0`` on success, and returns ``-1`` with an exception
|
||||
set on failure.
|
||||
|
||||
If this is not called in the main thread of the main
|
||||
interpreter, this function does nothing and returns ``0``.
|
||||
The caller must hold an :term:`attached thread state`.
|
||||
|
||||
.. versionadded:: 3.1
|
||||
|
||||
.. versionchanged:: 3.12
|
||||
This function only runs pending calls in the main interpreter.
|
||||
|
||||
|
||||
.. _profiling:
|
||||
|
||||
Profiling and Tracing
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue