File tree 3 files changed +5
-0
lines changed
3 files changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -410,6 +410,7 @@ pub enum Ordering {
410
410
note = "the `new` function is now preferred" ,
411
411
suggestion = "AtomicBool::new(false)"
412
412
) ]
413
+ #[ cfg_attr( not( bootstrap) , expect( interior_mutable_consts) ) ]
413
414
pub const ATOMIC_BOOL_INIT : AtomicBool = AtomicBool :: new ( false ) ;
414
415
415
416
#[ cfg( target_has_atomic_load_store = "8" ) ]
@@ -3691,6 +3692,7 @@ macro_rules! atomic_int_ptr_sized {
3691
3692
note = "the `new` function is now preferred" ,
3692
3693
suggestion = "AtomicIsize::new(0)" ,
3693
3694
) ]
3695
+ #[ cfg_attr( not( bootstrap) , expect( interior_mutable_consts) ) ]
3694
3696
pub const ATOMIC_ISIZE_INIT : AtomicIsize = AtomicIsize :: new( 0 ) ;
3695
3697
3696
3698
/// An [`AtomicUsize`] initialized to `0`.
@@ -3701,6 +3703,7 @@ macro_rules! atomic_int_ptr_sized {
3701
3703
note = "the `new` function is now preferred" ,
3702
3704
suggestion = "AtomicUsize::new(0)" ,
3703
3705
) ]
3706
+ #[ cfg_attr( not( bootstrap) , expect( interior_mutable_consts) ) ]
3704
3707
pub const ATOMIC_USIZE_INIT : AtomicUsize = AtomicUsize :: new( 0 ) ;
3705
3708
) * } ;
3706
3709
}
Original file line number Diff line number Diff line change @@ -71,6 +71,7 @@ pub(crate) enum ExclusiveState {
71
71
note = "the `Once::new()` function is now preferred" ,
72
72
suggestion = "Once::new()"
73
73
) ]
74
+ #[ cfg_attr( not( bootstrap) , expect( interior_mutable_consts) ) ]
74
75
pub const ONCE_INIT : Once = Once :: new ( ) ;
75
76
76
77
impl Once {
Original file line number Diff line number Diff line change @@ -55,6 +55,7 @@ pub macro thread_local_inner {
55
55
56
56
// Used to generate the `LocalKey` value for const-initialized thread locals.
57
57
( @key $t: ty, const $init: expr) => { {
58
+ #[ allow( unknown_lints, interior_mutable_consts) ] // cfg(bootstrap) for unknown_lints
58
59
const __INIT: $t = $init;
59
60
60
61
unsafe {
You can’t perform that action at this time.
0 commit comments