mirror of
https://github.com/isocpp/CppCoreGuidelines.git
synced 2025-12-18 21:24:41 +03:00
Exception of CP.100 refined to include the "sequentially consistent memory model" only
Atomic variables are safe with the sequentially consistent memory model (memory_order_seq_cst) only. Weakly ordered atomics cannot be considered safe for mainstream use. The exception clause of CP.100 refined to include the "sequentially consistent memory model" only. cst added to dictionary For std::memory_order_seq_cst, which is defined in <atomic>.
This commit is contained in:
@@ -12570,7 +12570,7 @@ Read up on the ABA problem.
|
||||
|
||||
##### Exception
|
||||
|
||||
[Atomic variables](#???) can be used simply and safely.
|
||||
[Atomic variables](#???) can be used simply and safely, as long as you are using the sequentially consistent memory model (memory_order_seq_cst), which is the default.
|
||||
|
||||
##### Note
|
||||
|
||||
|
||||
Reference in New Issue
Block a user