From dd4efac7d269feebc8fe9fc0e2c9bf02c28d462a Mon Sep 17 00:00:00 2001 From: Yuki Kobayashi Date: Tue, 17 Dec 2024 09:10:34 +0000 Subject: [PATCH] gh-118915: Add document of `PY_MONITORING_IS_INSTRUMENTED_EVENT` --- Doc/c-api/monitoring.rst | 6 ++++++ Doc/library/sys.monitoring.rst | 2 ++ 2 files changed, 8 insertions(+) diff --git a/Doc/c-api/monitoring.rst b/Doc/c-api/monitoring.rst index 51d866cfd47469..ccfb9def696689 100644 --- a/Doc/c-api/monitoring.rst +++ b/Doc/c-api/monitoring.rst @@ -190,3 +190,9 @@ would typically correspond to a python function. .. c:function:: int PyMonitoring_ExitScope(void) Exit the last scope that was entered with :c:func:`!PyMonitoring_EnterScope`. + + +.. c:function:: int PY_MONITORING_IS_INSTRUMENTED_EVENT(uint8_t ev) + + Return true if the event corresponding to event ID *ev* is + a :ref:`local event `. diff --git a/Doc/library/sys.monitoring.rst b/Doc/library/sys.monitoring.rst index f7140af2494898..3b016cedb48ef4 100644 --- a/Doc/library/sys.monitoring.rst +++ b/Doc/library/sys.monitoring.rst @@ -165,6 +165,8 @@ events, use the expression ``PY_RETURN | PY_START``. Events are divided into three groups: +.. _monitoring-event-local: + Local events ''''''''''''