File tree Expand file tree Collapse file tree 2 files changed +32
-0
lines changed Expand file tree Collapse file tree 2 files changed +32
-0
lines changed Original file line number Diff line number Diff line change @@ -100,6 +100,13 @@ extern DL_IMPORT(PyThreadState *) _PyThreadState_Current;
100
100
#define PyThreadState_GET () (_PyThreadState_Current)
101
101
#endif
102
102
103
+ /* Routines for advanced debuggers, requested by David Beazley.
104
+ Don't use unless you know what you are doing! */
105
+ DL_IMPORT (PyInterpreterState * ) PyInterpreterState_Head (void );
106
+ DL_IMPORT (PyInterpreterState * ) PyInterpreterState_Next (PyInterpreterState * );
107
+ DL_IMPORT (PyThreadState * ) PyInterpreterState_ThreadHead (PyInterpreterState * );
108
+ DL_IMPORT (PyThreadState * ) PyThreadState_Next (PyThreadState * );
109
+
103
110
#ifdef __cplusplus
104
111
}
105
112
#endif
Original file line number Diff line number Diff line change @@ -264,3 +264,28 @@ PyThreadState_GetDict(void)
264
264
_PyThreadState_Current -> dict = PyDict_New ();
265
265
return _PyThreadState_Current -> dict ;
266
266
}
267
+
268
+
269
+ /* Routines for advanced debuggers, requested by David Beazley.
270
+ Don't use unless you know what you are doing! */
271
+
272
+ PyInterpreterState *
273
+ PyInterpreterState_Head (void )
274
+ {
275
+ return interp_head ;
276
+ }
277
+
278
+ PyInterpreterState *
279
+ PyInterpreterState_Next (PyInterpreterState * interp ) {
280
+ return interp -> next ;
281
+ }
282
+
283
+ PyThreadState *
284
+ PyInterpreterState_ThreadHead (PyInterpreterState * interp ) {
285
+ return interp -> tstate_head ;
286
+ }
287
+
288
+ PyThreadState *
289
+ PyThreadState_Next (PyThreadState * tstate ) {
290
+ return tstate -> next ;
291
+ }
You can’t perform that action at this time.
0 commit comments