From Jason Turner

[thread.once.callonce]

Diff to HTML by rtfpessoa

tmp/tmpwj9xcclk/{from.md → to.md} RENAMED
@@ -8,18 +8,18 @@ template<class Callable, class... Args>
8
  *Mandates:* `is_invocable_v<Callable, Args...>` is `true`.
9
 
10
  *Effects:* An execution of `call_once` that does not call its `func` is
11
  a *passive* execution. An execution of `call_once` that calls its `func`
12
  is an *active* execution. An active execution calls *INVOKE*(
13
- std::forward\<Callable\>(func), std::forward\<Args\>(args)...). If such
14
- a call to `func` throws an exception the execution is *exceptional*,
15
- otherwise it is *returning*. An exceptional execution propagates the
16
- exception to the caller of `call_once`. Among all executions of
17
- `call_once` for any given `once_flag`: at most one is a returning
18
- execution; if there is a returning execution, it is the last active
19
- execution; and there are passive executions only if there is a returning
20
- execution.
21
 
22
  [*Note 1*: Passive executions allow other threads to reliably observe
23
  the results produced by the earlier returning execution. — *end note*]
24
 
25
  *Synchronization:* For any given `once_flag`: all active executions
 
8
  *Mandates:* `is_invocable_v<Callable, Args...>` is `true`.
9
 
10
  *Effects:* An execution of `call_once` that does not call its `func` is
11
  a *passive* execution. An execution of `call_once` that calls its `func`
12
  is an *active* execution. An active execution calls *INVOKE*(
13
+ std::forward\<Callable\>(func),
14
+ std::forward\<Args\>(args)...) [[func.require]]. If such a call to
15
+ `func` throws an exception the execution is *exceptional*, otherwise it
16
+ is *returning*. An exceptional execution propagates the exception to the
17
+ caller of `call_once`. Among all executions of `call_once` for any given
18
+ `once_flag`: at most one is a returning execution; if there is a
19
+ returning execution, it is the last active execution; and there are
20
+ passive executions only if there is a returning execution.
21
 
22
  [*Note 1*: Passive executions allow other threads to reliably observe
23
  the results produced by the earlier returning execution. — *end note*]
24
 
25
  *Synchronization:* For any given `once_flag`: all active executions