generic template (1) | void set_value_at_thread_exit (const T& val); void set_value_at_thread_exit (T&& val); |
---|---|
specializations (2) | void promise<R&>::set_value_at_thread_exit (R& val); // when T is a reference type (R&) void promise<void>::set_value_at_thread_exit (void); // when T is void |
exception type | error condition | description |
---|---|---|
future_error | future_errc::no_state | The object has no shared state (it was moved-from) |
future_error | future_errc::promise_already_satisfied | The shared state already has a stored value or exception |