GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
std::stop_token::stop_possible(3) C++ Standard Libary std::stop_token::stop_possible(3)

std::stop_token::stop_possible - std::stop_token::stop_possible


[[nodiscard]] bool stop_possible() const noexcept; (since C++20)


Checks if the stop_token object has associated stop-state, and that state either has
already had a stop requested or it has associated std::stop_source object(s).


A default constructed stop_token has no associated stop-state, and thus cannot be
stopped; the associated stop-state for which no std::stop_source object(s) exist can
also not be stopped if such a request has not already been made.


(none)


false if the stop_token object has no associated stop-state, or it did not yet
receive a stop request and there are no associated std::stop_source object(s); true
otherwise.


If the stop_token object has associated stop-state and a stop request has already
been made, this function still returns true.


If the stop_token object has associated stop-state from a std::jthread—for
example, the stop_token was retrieved by invoking get_stop_token() on a std::jthread
object—then this function always returns true. A std::jthread always has an
internal std::stop_source object, even if the thread's invoking function does not
check it.


This section is incomplete
Reason: no example

2022.07.31 http://cppreference.com

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.