@@ -91,7 +91,7 @@ extern "C" {
9191#define SLP_TASKLET_FLAGS_OFFSET_pending_irq \
9292 (SLP_TASKLET_FLAGS_OFFSET_is_zombie + SLP_TASKLET_FLAGS_BITS_is_zombie)
9393
94- typedef struct _tasklet_flags {
94+ typedef struct _slp_tasklet_flags {
9595 signed int blocked: SLP_TASKLET_FLAGS_BITS_blocked;
9696 unsigned int atomic: SLP_TASKLET_FLAGS_BITS_atomic;
9797 unsigned int ignore_nesting: SLP_TASKLET_FLAGS_BITS_ignore_nesting;
@@ -101,16 +101,16 @@ typedef struct _tasklet_flags {
101101 unsigned int pending_irq: SLP_TASKLET_FLAGS_BITS_pending_irq;
102102} PyTaskletFlagStruc;
103103
104- typedef struct _tasklet {
104+ typedef struct _slp_tasklet {
105105 PyObject_HEAD
106- struct _tasklet *next;
107- struct _tasklet *prev;
106+ struct _slp_tasklet *next;
107+ struct _slp_tasklet *prev;
108108 union {
109109 struct _frame *frame;
110110 struct _cframe *cframe;
111111 } f;
112112 PyObject *tempval;
113- struct _cstack *cstate;
113+ struct _slp_cstack *cstate;
114114 /* Pointer to the top of the stack of the exceptions currently
115115 * being handled */
116116 _PyErr_StackItem *exc_info;
@@ -119,7 +119,7 @@ typedef struct _tasklet {
119119 */
120120 _PyErr_StackItem exc_state;
121121 /* bits stuff */
122- struct _tasklet_flags flags;
122+ struct _slp_tasklet_flags flags;
123123 int recursion_depth;
124124 PyObject *def_globals;
125125 PyObject *tsk_weakreflist;
@@ -142,15 +142,15 @@ typedef struct _tasklet {
142142
143143/* ** important structures: cstack ***/
144144
145- typedef struct _cstack {
145+ typedef struct _slp_cstack {
146146 PyObject_VAR_HEAD
147- struct _cstack *next;
148- struct _cstack *prev;
147+ struct _slp_cstack *next;
148+ struct _slp_cstack *prev;
149149 PY_LONG_LONG serial;
150150 /* A borrowed reference to the tasklet, that owns this cstack. NULL after
151151 * the stack has been restored. Always NULL for an initial stub.
152152 */
153- struct _tasklet *task;
153+ struct _slp_tasklet *task;
154154 int nesting_level;
155155 PyThreadState *tstate;
156156#ifdef SLP_SEH32
@@ -179,7 +179,7 @@ typedef struct _cstack {
179179
180180/* ** important structures: bomb ***/
181181
182- typedef struct _bomb {
182+ typedef struct _slp_bomb {
183183 PyObject_HEAD
184184 PyObject *curexc_type;
185185 PyObject *curexc_value;
@@ -221,24 +221,24 @@ typedef struct _bomb {
221221#define SLP_CHANNEL_FLAGS_OFFSET_schedule_all \
222222 (SLP_CHANNEL_FLAGS_OFFSET_preference + SLP_CHANNEL_FLAGS_BITS_preference)
223223
224- typedef struct _channel_flags {
224+ typedef struct _slp_channel_flags {
225225 unsigned int closing: SLP_CHANNEL_FLAGS_BITS_closing;
226226 signed int preference: SLP_CHANNEL_FLAGS_BITS_preference;
227227 unsigned int schedule_all: SLP_CHANNEL_FLAGS_BITS_schedule_all;
228228} PyChannelFlagStruc;
229229
230- typedef struct _channel {
230+ typedef struct _slp_channel {
231231 PyObject_HEAD
232232 /* make sure that these fit tasklet's next/prev */
233- struct _tasklet *head;
234- struct _tasklet *tail;
233+ struct _slp_tasklet *head;
234+ struct _slp_tasklet *tail;
235235 int balance;
236- struct _channel_flags flags;
236+ struct _slp_channel_flags flags;
237237 PyObject *chan_weakreflist;
238238} PyChannelObject;
239239
240- struct _cframe ;
241- typedef PyObject *(PyFrame_ExecFunc) (struct _cframe *, int , PyObject *);
240+ struct _slp_cframe ;
241+ typedef PyObject *(PyFrame_ExecFunc) (struct _slp_cframe *, int , PyObject *);
242242/*
243243 * How to write frame execution functions:
244244 *
@@ -259,7 +259,7 @@ typedef PyObject *(PyFrame_ExecFunc) (struct _cframe *, int, PyObject *);
259259
260260/* ** important stuctures: cframe ***/
261261
262- typedef struct _cframe {
262+ typedef struct _slp_cframe {
263263 PyObject_VAR_HEAD
264264 struct _frame *f_back; /* previous frame, or NULL */
265265
@@ -278,18 +278,18 @@ typedef struct _cframe {
278278 void *any2;
279279} PyCFrameObject;
280280
281- typedef struct _unwindobject {
281+ typedef struct _slp_unwindobject {
282282 PyObject_HEAD
283283} PyUnwindObject;
284284
285285
286286#else /* #ifdef SLP_BUILD_CORE */
287287
288- typedef struct _channel PyChannelObject;
289- typedef struct _cframe PyCFrameObject;
290- typedef struct _tasklet PyTaskletObject;
291- typedef struct _unwindobject PyUnwindObject;
292- typedef struct _bomb PyBombObject;
288+ typedef struct _slp_channel PyChannelObject;
289+ typedef struct _slp_cframe PyCFrameObject;
290+ typedef struct _slp_tasklet PyTaskletObject;
291+ typedef struct _slp_unwindobject PyUnwindObject;
292+ typedef struct _slp_bomb PyBombObject;
293293
294294#endif /* #ifdef SLP_BUILD_CORE */
295295
0 commit comments