std::atomic<std::shared_ptr>
Min standard notice:
Header: <memory>
The partial template specialization of std::atomic for std::shared_ptr
# Declarations
template< class T >
struct std::atomic<std::shared_ptr<T>>;
(since C++20)
# Notes
Feature-test macro Value Std Feature __cpp_lib_atomic_shared_ptr 201711L (C++20) std::atomicstd::shared_ptr
# Example
This section is incompleteReason: no example
# Defect reports
| DR | Applied to | Behavior as published | Correct behavior |
|---|---|---|---|
| LWG 3661 | C++20 | atomic<shared_ptr | made constant-initializable |
| LWG 3893 | C++20 | LWG3661 made atomic<shared_ptr | assignability restored |