File tree 1 file changed +6
-6
lines changed
1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -344,20 +344,20 @@ mod serde;
344
344
#[ cfg( feature = "kv_unstable" ) ]
345
345
pub mod kv;
346
346
347
- #[ cfg( has_atomics ) ]
347
+ #[ cfg( target_has_atomic = "ptr" ) ]
348
348
use std:: sync:: atomic:: { AtomicUsize , Ordering } ;
349
349
350
- #[ cfg( not( has_atomics ) ) ]
350
+ #[ cfg( not( target_has_atomic = "ptr" ) ) ]
351
351
use std:: cell:: Cell ;
352
- #[ cfg( not( has_atomics ) ) ]
352
+ #[ cfg( not( target_has_atomic = "ptr" ) ) ]
353
353
use std:: sync:: atomic:: Ordering ;
354
354
355
- #[ cfg( not( has_atomics ) ) ]
355
+ #[ cfg( not( target_has_atomic = "ptr" ) ) ]
356
356
struct AtomicUsize {
357
357
v : Cell < usize > ,
358
358
}
359
359
360
- #[ cfg( not( has_atomics ) ) ]
360
+ #[ cfg( not( target_has_atomic = "ptr" ) ) ]
361
361
impl AtomicUsize {
362
362
const fn new ( v : usize ) -> AtomicUsize {
363
363
AtomicUsize { v : Cell :: new ( v) }
@@ -389,7 +389,7 @@ impl AtomicUsize {
389
389
390
390
// Any platform without atomics is unlikely to have multiple cores, so
391
391
// writing via Cell will not be a race condition.
392
- #[ cfg( not( has_atomics ) ) ]
392
+ #[ cfg( not( target_has_atomic = "ptr" ) ) ]
393
393
unsafe impl Sync for AtomicUsize { }
394
394
395
395
// The LOGGER static holds a pointer to the global logger. It is protected by
You can’t perform that action at this time.
0 commit comments