This page has been machine-translated from the English version of the wiki using Google Translate.
The translation may contain errors and awkward wording. Hover over text to see the original version. You can help to fix errors and improve the translation. For instructions click here.
Defined in header <mutex>
|(a partir do C++ 11)|
std::once_flag is a helper structure for std::call_once.
An object of type
std::once_flag that is passed to multiple calls to std::call_once allows those calls to coordinate with eachother such that only one of the calls will actually run to completion.
std::once_flag is noncopyable.
[editar] Funções de membro
once_flag object. The internal state is set to indicate that no function has been called yet.
[editar] Veja também
chama uma função apenas uma vez, mesmo se chamado de vários segmentos
(modelo de função)