std::stoppable_token
Min standard notice:
Header: <stop_token>
The concept stoppable_token
# Declarations
template< class Token >
concept stoppable_token =
requires (const Token tok) {
typename /*check-type-alias-exists*/<Token::template callback_type>;
{ tok.stop_requested() } noexcept -> std::same_as<bool>;
{ tok.stop_possible() } noexcept -> std::same_as<bool>;
{ Token(tok) } noexcept; // see implicit expression variations
} &&
std::copyable<Token> &&
std::equality_comparable<Token>;
(since C++26)
Helper templates
template< template<class> class >
struct /*check-type-alias-exists*/; // not defined
(exposition only*)