operator== (std::stop_token)
From cppreference.net
<
cpp
|
thread
|
stop token
C++
Concurrency support library
|
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
std::stop_token
| Member functions | ||||
| Modifiers | ||||
| Observers | ||||
| Non-member functions | ||||
|
operator==
|
|
friend
bool
operator
==
(
const
stop_token
&
lhs,
const
stop_token
&
rhs
)
noexcept
;
|
(C++20 起) | |
比较两个
stop_token
值。
此函数对普通的 非限定查找 或 限定查找 不可见,仅当 std::stop_token 作为参数的关联类时,才能通过 实参依赖查找 找到该函数。
!=
运算符由
默认比较
机制通过
operator==
自动合成。
参数
| lhs, rhs | - |
要比较的
stop_token
|
返回值
当 lhs 和 rhs 具有相同的关联停止状态,或两者均无关联停止状态时返回 true ,否则返回 false 。