File tree Expand file tree Collapse file tree 3 files changed +5
-0
lines changed Expand file tree Collapse file tree 3 files changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -410,6 +410,7 @@ pub enum Ordering {
410410 note = "the `new` function is now preferred" ,
411411 suggestion = "AtomicBool::new(false)"
412412) ]
413+ #[ cfg_attr( not( bootstrap) , expect( interior_mutable_consts) ) ]
413414pub const ATOMIC_BOOL_INIT : AtomicBool = AtomicBool :: new ( false ) ;
414415
415416#[ cfg( target_has_atomic_load_store = "8" ) ]
@@ -3691,6 +3692,7 @@ macro_rules! atomic_int_ptr_sized {
36913692 note = "the `new` function is now preferred" ,
36923693 suggestion = "AtomicIsize::new(0)" ,
36933694 ) ]
3695+ #[ cfg_attr( not( bootstrap) , expect( interior_mutable_consts) ) ]
36943696 pub const ATOMIC_ISIZE_INIT : AtomicIsize = AtomicIsize :: new( 0 ) ;
36953697
36963698 /// An [`AtomicUsize`] initialized to `0`.
@@ -3701,6 +3703,7 @@ macro_rules! atomic_int_ptr_sized {
37013703 note = "the `new` function is now preferred" ,
37023704 suggestion = "AtomicUsize::new(0)" ,
37033705 ) ]
3706+ #[ cfg_attr( not( bootstrap) , expect( interior_mutable_consts) ) ]
37043707 pub const ATOMIC_USIZE_INIT : AtomicUsize = AtomicUsize :: new( 0 ) ;
37053708 ) * } ;
37063709}
Original file line number Diff line number Diff line change @@ -71,6 +71,7 @@ pub(crate) enum ExclusiveState {
7171 note = "the `Once::new()` function is now preferred" ,
7272 suggestion = "Once::new()"
7373) ]
74+ #[ cfg_attr( not( bootstrap) , expect( interior_mutable_consts) ) ]
7475pub const ONCE_INIT : Once = Once :: new ( ) ;
7576
7677impl Once {
Original file line number Diff line number Diff line change @@ -55,6 +55,7 @@ pub macro thread_local_inner {
5555
5656 // Used to generate the `LocalKey` value for const-initialized thread locals.
5757 ( @key $t: ty, const $init: expr) => { {
58+ #[ allow( unknown_lints, interior_mutable_consts) ] // cfg(bootstrap) for unknown_lints
5859 const __INIT: $t = $init;
5960
6061 unsafe {
You can’t perform that action at this time.
0 commit comments