File tree Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -74,6 +74,9 @@ impl std::fmt::Debug for PyObjectObRefcnt {
7474#[ cfg( all( not( Py_3_12 ) , not( Py_GIL_DISABLED ) ) ) ]
7575pub type PyObjectObRefcnt = Py_ssize_t ;
7676
77+ const _PyGC_PREV_SHIFT: usize = 2 ;
78+ pub const _PyObject_MIN_ALIGNMENT: usize = 1 << _PyGC_PREV_SHIFT;
79+
7780// PyObject_HEAD_INIT comes before the PyObject definition in object.h
7881// but we put it after PyObject because HEAD_INIT uses PyObject
7982
@@ -114,7 +117,9 @@ pub const PyObject_HEAD_INIT: PyObject = PyObject {
114117 _ob_next : std:: ptr:: null_mut ( ) ,
115118 #[ cfg( py_sys_config = "Py_TRACE_REFS" ) ]
116119 _ob_prev : std:: ptr:: null_mut ( ) ,
117- #[ cfg( Py_GIL_DISABLED ) ]
120+ #[ cfg( all( Py_GIL_DISABLED , not( Py_3_15 ) ) ) ]
121+ ob_tid : 0 ,
122+ #[ cfg( all( Py_GIL_DISABLED , Py_3_15 ) ) ]
118123 ob_tid : 0 ,
119124 #[ cfg( all( Py_GIL_DISABLED , Py_3_14 ) ) ]
120125 ob_flags : 0 ,
Original file line number Diff line number Diff line change @@ -14,8 +14,10 @@ use std::ptr;
1414#[ cfg( Py_GIL_DISABLED ) ]
1515use std:: sync:: atomic:: Ordering :: Relaxed ;
1616
17- #[ cfg( Py_3_14 ) ]
17+ #[ cfg( all ( Py_3_14 , not ( Py_3_15 ) ) ) ]
1818const _Py_STATICALLY_ALLOCATED_FLAG: c_int = 1 << 7 ;
19+ #[ cfg( Py_3_15 ) ]
20+ const _Py_STATICALLY_ALLOCATED_FLAG: c_int = 1 << 2 ;
1921
2022#[ cfg( all( Py_3_12 , not( Py_3_14 ) ) ) ]
2123const _Py_IMMORTAL_REFCNT: Py_ssize_t = {
You can’t perform that action at this time.
0 commit comments