cpp/thread/packaged task/make ready at thread exit

Calls the stored task as if by, where is the stored task. The return value of the task or any exception thrown by it is stored in the shared state of.

The shared state is only made ready after the current thread exits and all objects of thread-local storage duration are destroyed.

Return value
(none)

Exceptions
std on the following error conditions:


 * The stored task has already been invoked. The error category is set to.
 * has no shared state. The error category is set to.