std::condition_variable::~condition_variable
From cppreference.com
< cpp | thread | condition variable
C++
Concurrency support library
|
|
std::condition_variable
Member functions | ||||
condition_variable::~condition_variable | ||||
Notification | ||||
Waiting | ||||
Native handle | ||||
~condition_variable(); |
(since C++11) | |
Destroys the object of type std::condition_variable.
Notes
It is only safe to invoke the destructor if all threads have been notified. It is not required that they have exited their respective wait functions: some threads may still be waiting to reacquire the associated lock, or may be waiting to be scheduled to run after reacquiring it.
The programmer must ensure that no threads attempt to wait on *this
See also
C documentation for cnd_destroy
|