Documentation Home >> Headers >> <jss/experimental_future.hpp> Header >> std::experimental::future >> std::experimental::future Move Assignment Operator

Transfer ownership of the asynchronous result associated with the one std::experimental::future object to another.

future(future&& other);

Effects:

Transfers ownership of an asynchronous state between std::experimental::future instances.

Postconditions:

The asynchronous result associated with other prior to the invocation of the constructor is associated with *this. other has no associated asynchronous result. The ownership of the asynchronous state (if any) associated with *this prior to the call is released, and the state destroyed if this is the last reference. this->valid() returns the same value that other.valid() returned before the invocation of this constructor. other.valid() returns false.

Throws:

Nothing.

Header

#include <experimental/future>

See Also