Movatterモバイル変換


[0]ホーム

URL:


cppreference.com
Namespaces
Variants
    Actions

      std::move_iterator<Iter>::operator=

      From cppreference.com
      <cpp‎ |iterator‎ |move iterator
       
       
      Iterator library
      Iterator concepts
      Iterator primitives
      Algorithm concepts and utilities
      Indirect callable concepts
      Common algorithm requirements
      (C++20)
      (C++20)
      (C++20)
      Utilities
      (C++20)
      Iterator adaptors
      Range access
      (C++11)(C++14)
      (C++14)(C++14)  
      (C++11)(C++14)
      (C++14)(C++14)  
      (C++17)(C++20)
      (C++17)
      (C++17)
       
       
      template<class U>
      move_iterator& operator=(const move_iterator<U>& other);
      (constexpr since C++17)

      Assignsother.current tocurrent .

      IfU is not convertible toIter, the program is ill-formed.

      (until C++20)

      This overload participates in overload resolution only ifstd::is_same_v<U, Iter> isfalse and bothstd::convertible_to<const U&, Iter> andstd::assignable_from<Iter&,const U&> are modeled.

      (since C++20)

      Contents

      [edit]Parameters

      other - iterator adaptor to assign

      [edit]Return value

      *this

      [edit]Example

      This section is incomplete
      Reason: no example

      [edit]Defect reports

      The following behavior-changing defect reports were applied retroactively to previously published C++ standards.

      DRApplied toBehavior as publishedCorrect behavior
      LWG 3435C++20the converting assignment operator was not constrainedconstrained

      [edit]See also

      constructs a newmove_iterator
      (public member function)[edit]
      Retrieved from "https://en.cppreference.com/mwiki/index.php?title=cpp/iterator/move_iterator/operator%3D&oldid=177387"

      [8]ページ先頭

      ©2009-2026 Movatter.jp