std::experimental::shared_future<T>::operator=
来自cppreference.com
< cpp | experimental | shared future
std::experimental::shared_future<T>& operator=( const std::experimental::shared_future<T>& other ); |
(1) | |
std::experimental::shared_future<T>& operator=( std::experimental::shared_future<T>&& other ) noexcept; |
(2) | |
赋值另一 std::experimental::shared_future
对象的内容。
1) 释放任何共享状态并赋值
other
的内容给 *this 。赋值后, this->valid() == other.valid() 。2) 释放任何共享状态并移动赋值
other
的内容给 *this 。赋值后, other.valid() == false 而 this->valid() 将生成与 other.valid() 在赋值前相同的值。参数
other | - | 赋值来源的 std::experimental::shared_future
|
返回值
*this