Namespaces
Variants
Views
Actions

operator+(std::move_iterator)

From cppreference.com
 
 
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)
 
 
Defined in header <iterator>
template< class Iter >

move_iterator<Iter>
    operator+( typename move_iterator<Iter>::difference_type n,

               const move_iterator<Iter>& it );
(since C++11)
(until C++17)
template< class Iter >

constexpr move_iterator<Iter>
    operator+( typename move_iterator<Iter>::difference_type n,

               const move_iterator<Iter>& it );
(since C++17)
Returns the iterator it incremented by n.

This overload participates in overload resolution only if it.base() + n is well-formed and has type Iter.

(since C++20)

Contents

[edit] Parameters

n - the number of positions to increment the iterator
it - the iterator adaptor to increment

[edit] Return value

The incremented iterator, that is move_iterator<Iter>(it.base() + n).

[edit] Example

[edit] See also

advances or decrements the iterator
(public member function) [edit]
(C++11)
computes the distance between two iterator adaptors
(function template) [edit]