File tree Expand file tree Collapse file tree 1 file changed +10
-7
lines changed
Expand file tree Collapse file tree 1 file changed +10
-7
lines changed Original file line number Diff line number Diff line change @@ -119,25 +119,28 @@ typedef enum {
119119 PyObject *prefix##_result; \
120120 PyObject *prefix##_source_tb; \
121121 PyObject *prefix##_cancel_msg; \
122- fut_state prefix##_state; \
123- int prefix##_log_tb; \
124- int prefix##_blocking; \
125122 PyObject *prefix##_weakreflist; \
126- PyObject *prefix##_cancelled_exc;
123+ PyObject *prefix##_cancelled_exc; \
124+ fut_state prefix##_state; \
125+ /* These bitfields need to be at the end of the struct
126+ so that these and bitfields from TaskObj are contiguous.
127+ */ \
128+ unsigned prefix ##_log_tb : 1 ; \
129+ unsigned prefix ##_blocking : 1 ;
127130
128131typedef struct {
129132 FutureObj_HEAD (fut )
130133} FutureObj ;
131134
132135typedef struct {
133136 FutureObj_HEAD (task )
137+ unsigned task_must_cancel : 1 ;
138+ unsigned task_log_destroy_pending : 1 ;
139+ int task_num_cancels_requested ;
134140 PyObject * task_fut_waiter ;
135141 PyObject * task_coro ;
136142 PyObject * task_name ;
137143 PyObject * task_context ;
138- int task_must_cancel ;
139- int task_log_destroy_pending ;
140- int task_num_cancels_requested ;
141144} TaskObj ;
142145
143146typedef struct {
You can’t perform that action at this time.
0 commit comments