32 Concurrency support library [thread] (original) (raw)

Effects: As if by INVOKE<R>(f, t, t, …, t) ([func.require]), where f is the stored task andt, t, …, t are the values in args....

If the task returns normally, the return value is stored as the asynchronous result in the shared state of*this, otherwise the exception thrown by the task is stored.

In either case, this is done without making that state ready ([futures.state]) immediately.

Schedules the shared state to be made ready when the current thread exits, after all objects with thread storage duration associated with the current thread have been destroyed.