about summary refs log tree commit diff
path: root/src/libcore/sync
diff options
context:
space:
mode:
authorRalf Jung <post@ralfj.de>2018-08-07 11:26:05 +0200
committerRalf Jung <post@ralfj.de>2018-08-07 11:26:05 +0200
commit110bcc97984fec55cb6c0bd5313bcd8ee02da12c (patch)
treef2bfae248ca6295e36600a0a10425db4b9721892 /src/libcore/sync
parente9a86a2e1ae69ea733c5e8fdd976b9b41668fec2 (diff)
downloadrust-110bcc97984fec55cb6c0bd5313bcd8ee02da12c.tar.gz
rust-110bcc97984fec55cb6c0bd5313bcd8ee02da12c.zip
forgot to add comment for some atomic types
Diffstat (limited to 'src/libcore/sync')
-rw-r--r--src/libcore/sync/atomic.rs6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/libcore/sync/atomic.rs b/src/libcore/sync/atomic.rs
index 3f35067f4f5..7867998d058 100644
--- a/src/libcore/sync/atomic.rs
+++ b/src/libcore/sync/atomic.rs
@@ -843,7 +843,8 @@ impl<T> AtomicPtr<T> {
     /// was updated.
     ///
     /// `compare_and_swap` also takes an [`Ordering`] argument which describes the memory
-    /// ordering of this operation.
+    /// ordering of this operation. Notice that even when using [`AcqRel`], the operation
+    /// might fail and hence just perform an `Acquire` load, but not have `Release` semantics.
     ///
     /// [`Ordering`]: enum.Ordering.html
     ///
@@ -1202,7 +1203,8 @@ The return value is always the previous value. If it is equal to `current`, then
 value was updated.
 
 `compare_and_swap` also takes an [`Ordering`] argument which describes the memory
-ordering of this operation.
+ordering of this operation. Notice that even when using [`AcqRel`], the operation
+might fail and hence just perform an `Acquire` load, but not have `Release` semantics.
 
 [`Ordering`]: enum.Ordering.html