Commit 1968565 1 parent c9273f1 commit 1968565 Copy full SHA for 1968565
File tree 3 files changed +3
-12
lines changed
3 files changed +3
-12
lines changed Original file line number Diff line number Diff line change @@ -24,10 +24,7 @@ impl AtomicU16 {
24
24
/// Additionally, there must be no concurrent mutations.
25
25
pub ( crate ) unsafe fn unsync_load ( & self ) -> u16 {
26
26
// See <https://github.com/tokio-rs/tokio/issues/6155>
27
- #[ cfg( miri) ]
28
- return self . load ( std:: sync:: atomic:: Ordering :: Relaxed ) ;
29
- #[ cfg( not( miri) ) ]
30
- return core:: ptr:: read ( self . inner . get ( ) as * const u16 ) ;
27
+ self . load ( std:: sync:: atomic:: Ordering :: Relaxed )
31
28
}
32
29
}
33
30
Original file line number Diff line number Diff line change @@ -24,10 +24,7 @@ impl AtomicU32 {
24
24
/// Additionally, there must be no concurrent mutations.
25
25
pub ( crate ) unsafe fn unsync_load ( & self ) -> u32 {
26
26
// See <https://github.com/tokio-rs/tokio/issues/6155>
27
- #[ cfg( miri) ]
28
- return self . load ( std:: sync:: atomic:: Ordering :: Relaxed ) ;
29
- #[ cfg( not( miri) ) ]
30
- return core:: ptr:: read ( self . inner . get ( ) as * const u32 ) ;
27
+ self . load ( std:: sync:: atomic:: Ordering :: Relaxed )
31
28
}
32
29
}
33
30
Original file line number Diff line number Diff line change @@ -24,10 +24,7 @@ impl AtomicUsize {
24
24
/// Additionally, there must be no concurrent mutations.
25
25
pub ( crate ) unsafe fn unsync_load ( & self ) -> usize {
26
26
// See <https://github.com/tokio-rs/tokio/issues/6155>
27
- #[ cfg( miri) ]
28
- return self . load ( std:: sync:: atomic:: Ordering :: Relaxed ) ;
29
- #[ cfg( not( miri) ) ]
30
- return core:: ptr:: read ( self . inner . get ( ) as * const usize ) ;
27
+ self . load ( std:: sync:: atomic:: Ordering :: Relaxed )
31
28
}
32
29
33
30
pub ( crate ) fn with_mut < R > ( & mut self , f : impl FnOnce ( & mut usize ) -> R ) -> R {
You can’t perform that action at this time.
0 commit comments