Skip to content
This repository was archived by the owner on Oct 12, 2022. It is now read-only.

Commit af5b01e

Browse files
Merge pull request #2360 from n8sh/issue-19398-followup
Update core.atomic.MemoryOrder docs to mention relation to C++11/C11
2 parents 4978a08 + 983f430 commit af5b01e

File tree

1 file changed

+16
-6
lines changed

1 file changed

+16
-6
lines changed

src/core/atomic.d

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -255,18 +255,28 @@ version (CoreDdoc)
255255
*/
256256
enum MemoryOrder
257257
{
258-
/// Not sequenced.
259-
/// Corresponds to $(LINK2 https://llvm.org/docs/Atomics.html#monotonic, LLVM AtomicOrdering.Monotonic).
258+
/++
259+
Not sequenced.
260+
Corresponds to $(LINK2 https://llvm.org/docs/Atomics.html#monotonic, LLVM AtomicOrdering.Monotonic)
261+
and C++11/C11 `memory_order_relaxed`.
262+
+/
260263
raw,
261-
/// Hoist-load + hoist-store barrier.
262-
/// Corresponds to $(LINK2 https://llvm.org/docs/Atomics.html#acquire, LLVM AtomicOrdering.Acquire).
264+
/++
265+
Hoist-load + hoist-store barrier.
266+
Corresponds to $(LINK2 https://llvm.org/docs/Atomics.html#acquire, LLVM AtomicOrdering.Acquire)
267+
and C++11/C11 `memory_order_acquire`.
268+
+/
263269
acq,
264-
/// Sink-load + sink-store barrier.
265-
/// Corresponds to $(LINK2 https://llvm.org/docs/Atomics.html#release, LLVM AtomicOrdering.Release).
270+
/++
271+
Sink-load + sink-store barrier.
272+
Corresponds to $(LINK2 https://llvm.org/docs/Atomics.html#release, LLVM AtomicOrdering.Release)
273+
and C++11/C11 `memory_order_release`.
274+
+/
266275
rel,
267276
/++
268277
Fully sequenced (acquire + release). Corresponds to
269278
$(LINK2 https://llvm.org/docs/Atomics.html#sequentiallyconsistent, LLVM AtomicOrdering.SequentiallyConsistent)
279+
and C++11/C11 `memory_order_seq_cst`.
270280
+/
271281
seq,
272282
}

0 commit comments

Comments
 (0)