std::shared_future<T>::operator=
| (1) | ||
shared_future& operator=( const shared_future& other ); |
(с C++11) (до C++17) | |
shared_future& operator=( const shared_future& other ) noexcept; | (с C++17) | |
shared_future& operator=( shared_future&& other ) noexcept; | (2) | (с C++11) |
Присваивает содержимое другого shared_future.
1) Освобождает любые общие состояния и присваивает содержимое
other в *this. После присваивания, this->valid() == other.valid().
2) Освобождает любые общие состояния и переносит содержимое
other в *this. После присваивания, other.valid() == false и this->valid() будут возвращать то же значение, что и other.valid() до присваивания.Параметры
| other | - | std::shared_future , который передаст состояние в *this |
Возвращаемое значение
*this
© cppreference.com
Licensed under the Creative Commons Attribution-ShareAlike Unported License v3.0.
https://en.cppreference.com/w/cpp/thread/shared_future/operator%3D