File tree 5 files changed +6
-6
lines changed
5 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -153,7 +153,7 @@ static inline Py_ssize_t PyCode_GetNumFree(PyCodeObject *op) {
153
153
return op -> co_nfreevars ;
154
154
}
155
155
156
- #define _PyCode_CODE (CO ) ((_Py_CODEUNIT *)(CO)->co_code_adaptive)
156
+ #define _PyCode_CODE (CO ) _Py_RVALUE ((_Py_CODEUNIT *)(CO)->co_code_adaptive)
157
157
#define _PyCode_NBYTES (CO ) (Py_SIZE(CO) * (Py_ssize_t)sizeof(_Py_CODEUNIT))
158
158
159
159
/* Public interface */
Original file line number Diff line number Diff line change @@ -122,7 +122,7 @@ struct _dictvalues {
122
122
PyObject * values [1 ];
123
123
};
124
124
125
- #define DK_LOG_SIZE (dk ) ((dk)->dk_log2_size)
125
+ #define DK_LOG_SIZE (dk ) _Py_RVALUE ((dk)->dk_log2_size)
126
126
#if SIZEOF_VOID_P > 4
127
127
#define DK_SIZE (dk ) (((int64_t)1)<<DK_LOG_SIZE(dk))
128
128
#else
Original file line number Diff line number Diff line change @@ -18,9 +18,9 @@ typedef struct {
18
18
_Py_slist_item_t * head ;
19
19
} _Py_slist_t ;
20
20
21
- #define _Py_SLIST_ITEM_NEXT (ITEM ) (((_Py_slist_item_t *)(ITEM))->next)
21
+ #define _Py_SLIST_ITEM_NEXT (ITEM ) _Py_RVALUE (((_Py_slist_item_t *)(ITEM))->next)
22
22
23
- #define _Py_SLIST_HEAD (SLIST ) (((_Py_slist_t *)(SLIST))->head)
23
+ #define _Py_SLIST_HEAD (SLIST ) _Py_RVALUE (((_Py_slist_t *)(SLIST))->head)
24
24
25
25
26
26
/* _Py_hashtable: table entry */
Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ struct _Py_list_state {
35
35
#endif
36
36
};
37
37
38
- #define _PyList_ITEMS (op ) (_PyList_CAST(op)->ob_item)
38
+ #define _PyList_ITEMS (op ) _Py_RVALUE (_PyList_CAST(op)->ob_item)
39
39
40
40
extern int
41
41
_PyList_AppendTakeRefListResize (PyListObject * self , PyObject * newitem );
Original file line number Diff line number Diff line change @@ -62,7 +62,7 @@ struct _Py_tuple_state {
62
62
#endif
63
63
};
64
64
65
- #define _PyTuple_ITEMS (op ) (_PyTuple_CAST(op)->ob_item)
65
+ #define _PyTuple_ITEMS (op ) _Py_RVALUE (_PyTuple_CAST(op)->ob_item)
66
66
67
67
extern PyObject * _PyTuple_FromArray (PyObject * const * , Py_ssize_t );
68
68
extern PyObject * _PyTuple_FromArraySteal (PyObject * const * , Py_ssize_t );
You can’t perform that action at this time.
0 commit comments