std::experimental::ranges::tagged<Base,Tags...>::operator=
< cpp | experimental | ranges | utility/tagged
tagged &operator=( tagged&& that ) = default;
|
(1) | |
tagged &operator=( const tagged& that ) = default;
|
(2) | |
template< class Other >
requires Assignable<Base&, Other> |
(3) | |
template< class Other >
requires Assignable<Base&, const Other&> |
(4) | |
template< class U >
requires Assignable<Base&, U> && !Same<std::decay_t<U>, tagged> |
(5) | |
赋值 that 的内容给 *this。
1,2)
tagged
拥有默认化的复制和移动赋值运算符,它们调用 Base
的对应赋值运算符。3) 源自带匹配标签的相异
tagged
特化的转换移动赋值运算符。等价于 static_cast<Base&>(*this) = static_cast<Other&&>(that);。4) 源自带匹配标签的相异
tagged
特化转换复制赋值运算符。等价于 static_cast<Base&>(*this) = static_cast<const Other&>(that);。返回值
*this
。