Namespaces
Variants
Views
Actions

std::atomic_flag

From cppreference.com
< cpp‎ | atomic
Revision as of 05:55, 20 September 2011 by Cubbi (Talk | contribs)

Template:cpp/atomic/sidebar Template:ddcl list begin <tr class="t-dsc-header">

<td>
Defined in header <atomic>
</td>

<td></td> <td></td> </tr> <tr class="t-dcl ">

<td >
class atomic_flag;
</td>

<td class="t-dcl-nopad"> </td> <td > Template:mark c++11 feature </td> </tr> Template:ddcl list end

An Template:cpp is an atomic boolean type. Unlike all specializations of Template:cpp, it is guaranteed to be lock-free.

Member functions

constructs an atomic_flag
(public member function)
the assignment operator
(public member function)
atomically sets flag to Template:cpp
(public member function)
atomically sets the flag to Template:cpp and obtains its previous value
(public member function)

Example

Template:example cpp

See also

Template:cpp/atomic/dcl list ATOMIC FLAG INIT
atomically sets the flag to Template:cpp and returns its previous value
(function)
atomically sets the value of the flag to Template:cpp
(function)