@@ -133,7 +133,7 @@ Managing the Monitoring State
133
133
Monitoring states can be managed with the help of monitoring scopes. A scope
134
134
would typically correspond to a python function.
135
135
136
- .. : c:function:: int PyMonitoring_EnterScope(PyMonitoringState *state_array, uint64_t *version, const uint8_t *event_types, Py_ssize_t length)
136
+ .. c :function :: int PyMonitoring_EnterScope (PyMonitoringState *state_array, uint64_t *version, const uint8_t *event_types, Py_ssize_t length)
137
137
138
138
Enter a monitored scope. ``event_types `` is an array of the event IDs for
139
139
events that may be fired from the scope. For example, the ID of a ``PY_START ``
@@ -158,7 +158,35 @@ would typically correspond to a python function.
158
158
execution is paused, such as when emulating a generator, the scope needs to
159
159
be exited and re-entered.
160
160
161
-
162
- .. :c:function:: int PyMonitoring_ExitScope(void)
161
+ The macros for *event_types* are:
162
+
163
+ .. c:namespace:: NULL
164
+
165
+ .. The table is here to make the docs searchable, and to allow automatic
166
+ links to the identifiers.
167
+
168
+ ================================================== =====================================
169
+ Macro Event
170
+ ================================================== =====================================
171
+ .. c:macro:: PY_MONITORING_EVENT_BRANCH :monitoring-event:`BRANCH`
172
+ .. c:macro:: PY_MONITORING_EVENT_CALL :monitoring-event:`CALL`
173
+ .. c:macro:: PY_MONITORING_EVENT_C_RAISE :monitoring-event:`C_RAISE`
174
+ .. c:macro:: PY_MONITORING_EVENT_C_RETURN :monitoring-event:`C_RETURN`
175
+ .. c:macro:: PY_MONITORING_EVENT_EXCEPTION_HANDLED :monitoring-event:`EXCEPTION_HANDLED`
176
+ .. c:macro:: PY_MONITORING_EVENT_INSTRUCTION :monitoring-event:`INSTRUCTION`
177
+ .. c:macro:: PY_MONITORING_EVENT_JUMP :monitoring-event:`JUMP`
178
+ .. c:macro:: PY_MONITORING_EVENT_LINE :monitoring-event:`LINE`
179
+ .. c:macro:: PY_MONITORING_EVENT_PY_RESUME :monitoring-event:`PY_RESUME`
180
+ .. c:macro:: PY_MONITORING_EVENT_PY_RETURN :monitoring-event:`PY_RETURN`
181
+ .. c:macro:: PY_MONITORING_EVENT_PY_START :monitoring-event:`PY_START`
182
+ .. c:macro:: PY_MONITORING_EVENT_PY_THROW :monitoring-event:`PY_THROW`
183
+ .. c:macro:: PY_MONITORING_EVENT_PY_UNWIND :monitoring-event:`PY_UNWIND`
184
+ .. c:macro:: PY_MONITORING_EVENT_PY_YIELD :monitoring-event:`PY_YIELD`
185
+ .. c:macro:: PY_MONITORING_EVENT_RAISE :monitoring-event:`RAISE`
186
+ .. c:macro:: PY_MONITORING_EVENT_RERAISE :monitoring-event:`RERAISE`
187
+ .. c:macro:: PY_MONITORING_EVENT_STOP_ITERATION :monitoring-event:`STOP_ITERATION`
188
+ ================================================== =====================================
189
+
190
+ .. c:function:: int PyMonitoring_ExitScope(void)
163
191
164
192
Exit the last scope that was entered with ``PyMonitoring_EnterScope``.
0 commit comments