std::future<T>::operator=
From cppreference.com
| future& operator=( future&& other ) noexcept; |
(1) | (C++11以降) |
| future& operator=( const future& other ) = delete; |
(2) | (C++11以降) |
別の future オブジェクトの内容を代入します。
1) 共有状態を解放し、other の内容を *this にムーブ代入します。代入後、other.valid() は false となり、this->valid() は代入前の other.valid() と同じ値を返します。
2) std::future は CopyAssignable ではありません。
[編集] パラメータ
| その他 | - | state を *this に転送する std::future |
[編集] 戻り値
*this