@@ -563,8 +563,8 @@ impl AtomicBool {
563
563
/// `align_of::<AtomicBool>() == 1`).
564
564
/// * `ptr` must be [valid] for both reads and writes for the whole lifetime `'a`.
565
565
/// * You must adhere to the [Memory model for atomic accesses]. In particular, it is not
566
- /// allowed to mix atomic and non-atomic accesses, or atomic accesses of different sizes,
567
- /// without synchronization.
566
+ /// allowed to mix conflicting atomic and non-atomic accesses, or atomic accesses of different
567
+ /// sizes, without synchronization.
568
568
///
569
569
/// [valid]: crate::ptr#safety
570
570
/// [Memory model for atomic accesses]: self#memory-model-for-atomic-accesses
@@ -1246,7 +1246,7 @@ impl AtomicBool {
1246
1246
/// atomic types work with interior mutability. All modifications of an atomic change the value
1247
1247
/// through a shared reference, and can do so safely as long as they use atomic operations. Any
1248
1248
/// use of the returned raw pointer requires an `unsafe` block and still has to uphold the same
1249
- /// restriction: operations on it must be atomic.
1249
+ /// restriction in [Memory model for atomic accesses] .
1250
1250
///
1251
1251
/// # Examples
1252
1252
///
@@ -1264,6 +1264,8 @@ impl AtomicBool {
1264
1264
/// }
1265
1265
/// # }
1266
1266
/// ```
1267
+ ///
1268
+ /// [Memory model for atomic accesses]: self#memory-model-for-atomic-accesses
1267
1269
#[ inline]
1268
1270
#[ stable( feature = "atomic_as_ptr" , since = "1.70.0" ) ]
1269
1271
#[ rustc_const_stable( feature = "atomic_as_ptr" , since = "1.70.0" ) ]
@@ -1519,8 +1521,8 @@ impl<T> AtomicPtr<T> {
1519
1521
/// can be bigger than `align_of::<*mut T>()`).
1520
1522
/// * `ptr` must be [valid] for both reads and writes for the whole lifetime `'a`.
1521
1523
/// * You must adhere to the [Memory model for atomic accesses]. In particular, it is not
1522
- /// allowed to mix atomic and non-atomic accesses, or atomic accesses of different sizes,
1523
- /// without synchronization.
1524
+ /// allowed to mix conflicting atomic and non-atomic accesses, or atomic accesses of different
1525
+ /// sizes, without synchronization.
1524
1526
///
1525
1527
/// [valid]: crate::ptr#safety
1526
1528
/// [Memory model for atomic accesses]: self#memory-model-for-atomic-accesses
@@ -2488,7 +2490,7 @@ impl<T> AtomicPtr<T> {
2488
2490
/// atomic types work with interior mutability. All modifications of an atomic change the value
2489
2491
/// through a shared reference, and can do so safely as long as they use atomic operations. Any
2490
2492
/// use of the returned raw pointer requires an `unsafe` block and still has to uphold the same
2491
- /// restriction: operations on it must be atomic.
2493
+ /// restriction in [Memory model for atomic accesses] .
2492
2494
///
2493
2495
/// # Examples
2494
2496
///
@@ -2507,6 +2509,8 @@ impl<T> AtomicPtr<T> {
2507
2509
/// my_atomic_op(atomic.as_ptr());
2508
2510
/// }
2509
2511
/// ```
2512
+ ///
2513
+ /// [Memory model for atomic accesses]: self#memory-model-for-atomic-accesses
2510
2514
#[ inline]
2511
2515
#[ stable( feature = "atomic_as_ptr" , since = "1.70.0" ) ]
2512
2516
#[ rustc_const_stable( feature = "atomic_as_ptr" , since = "1.70.0" ) ]
@@ -2696,8 +2700,8 @@ macro_rules! atomic_int {
2696
2700
} ]
2697
2701
/// * `ptr` must be [valid] for both reads and writes for the whole lifetime `'a`.
2698
2702
/// * You must adhere to the [Memory model for atomic accesses]. In particular, it is not
2699
- /// allowed to mix atomic and non-atomic accesses, or atomic accesses of different sizes,
2700
- /// without synchronization.
2703
+ /// allowed to mix conflicting atomic and non-atomic accesses, or atomic accesses of different
2704
+ /// sizes, without synchronization.
2701
2705
///
2702
2706
/// [valid]: crate::ptr#safety
2703
2707
/// [Memory model for atomic accesses]: self#memory-model-for-atomic-accesses
@@ -3618,7 +3622,7 @@ macro_rules! atomic_int {
3618
3622
/// atomic types work with interior mutability. All modifications of an atomic change the value
3619
3623
/// through a shared reference, and can do so safely as long as they use atomic operations. Any
3620
3624
/// use of the returned raw pointer requires an `unsafe` block and still has to uphold the same
3621
- /// restriction: operations on it must be atomic.
3625
+ /// restriction in [Memory model for atomic accesses] .
3622
3626
///
3623
3627
/// # Examples
3624
3628
///
@@ -3638,6 +3642,8 @@ macro_rules! atomic_int {
3638
3642
/// }
3639
3643
/// # }
3640
3644
/// ```
3645
+ ///
3646
+ /// [Memory model for atomic accesses]: self#memory-model-for-atomic-accesses
3641
3647
#[ inline]
3642
3648
#[ stable( feature = "atomic_as_ptr" , since = "1.70.0" ) ]
3643
3649
#[ rustc_const_stable( feature = "atomic_as_ptr" , since = "1.70.0" ) ]
0 commit comments