std::move_iterator<Iter>::operator=
来自cppreference.com
< cpp | iterator | move iterator
| template< class U > move_iterator& operator=( const move_iterator<U>& other ); |
(C++17 前) | |
| template< class U > constexpr move_iterator& operator=( const move_iterator<U>& other ); |
(C++17 起) | |
对底层迭代器赋 other 的底层迭代器的值,即 other.base()。
如果 U 不可转换为 Iter,那么行为未定义。
|
(C++20 前) |
|
此重载只有在 |
(C++20 起) |
参数
| other | - | 要赋值的迭代器适配器 |
返回值
*this
示例
| 本节未完成 原因:暂无示例 |
缺陷报告
下列更改行为的缺陷报告追溯地应用于以前出版的 C++ 标准。
| 缺陷报告 | 应用于 | 出版时的行为 | 正确行为 |
|---|---|---|---|
| LWG 3435 | C++20 | 转换赋值运算符未受约束 | 已约束 |
参阅
| (C++11) |
构造新的迭代器适配器 (公开成员函数) |