C++11

// <atomic> 
// 类模板(1)    
template <class T>
void atomic_store_explicit (volatile atomic<T>* obj,
    T val, memory_order sync) noexcept;
template <class T>
void atomic_store_explicit (atomic<T>* obj,
    T val, memory_order sync) noexcept;
// 重载(2)    
void atomic_store_explicit (volatile A* obj, T val,
    memory_order sync) noexcept;
void atomic_store_explicit (A* obj, T val,
​    memory_order sync) noexcept;

用一个非原子(Non-atomic)参数原子替换(Atomically replace)指定原子对象的值。