If the
stoppable-source is disengaged,
request_stop shall have no effect and return
false. A stop request operation determines
whether the stop state has received a stop request, and
if not, makes a stop request
. The determination and making of the stop request shall happen atomically,
as-if by a read-modify-write operation (
[intro.races])
. If the request was made,
the stop state's registered callback invocations shall be
synchronously executed
. If an invocation of a callback exits via an exception
then terminate shall be invoked (
[except.terminate])
. [
Note 2:
No constraint is placed on the order
in which the callback invocations are executed
. —
end note]
request_stop shall return
true if a stop request was made, and
false otherwise
. After a call to
request_stop either
a call to
stop_possible shall return
false or
a call to
stop_requested shall return
true. [
Note 3:
A stop request includes notifying
all condition variables of type
condition_variable_any
temporarily registered during
an interruptible wait (
[thread.condvarany.intwait])
. —
end note]