[range.iter.op.next]

# 24 Iterators library [[iterators]](./#iterators)

## 24.4 Iterator primitives [[iterator.primitives]](iterator.primitives#range.iter.op.next)

### 24.4.4 Range iterator operations [[range.iter.ops]](range.iter.ops#range.iter.op.next)

#### 24.4.4.4 ranges​::​next [range.iter.op.next]

[ð](#lib:next)

`template<[input_or_output_iterator](iterator.concept.iterator#concept:input_or_output_iterator "24.3.4.6 Concept input_­or_­output_­iterator [iterator.concept.iterator]") I>
  constexpr I ranges::next(I x);
`

[1](#1)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iterators.tex#L3101)

*Effects*: Equivalent to: ++x; return x;

[ð](#lib:next_)

`template<[input_or_output_iterator](iterator.concept.iterator#concept:input_or_output_iterator "24.3.4.6 Concept input_­or_­output_­iterator [iterator.concept.iterator]") I>
  constexpr I ranges::next(I x, iter_difference_t<I> n);
`

[2](#2)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iterators.tex#L3113)

*Effects*: Equivalent to: ranges​::​advance(x, n); return x;

[ð](#lib:next__)

`template<[input_or_output_iterator](iterator.concept.iterator#concept:input_or_output_iterator "24.3.4.6 Concept input_­or_­output_­iterator [iterator.concept.iterator]") I, [sentinel_for](iterator.concept.sentinel#concept:sentinel_for "24.3.4.7 Concept sentinel_­for [iterator.concept.sentinel]")<I> S>
  constexpr I ranges::next(I x, S bound);
`

[3](#3)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iterators.tex#L3125)

*Effects*: Equivalent to: ranges​::​advance(x, bound); return x;

[ð](#lib:next___)

`template<[input_or_output_iterator](iterator.concept.iterator#concept:input_or_output_iterator "24.3.4.6 Concept input_­or_­output_­iterator [iterator.concept.iterator]") I, [sentinel_for](iterator.concept.sentinel#concept:sentinel_for "24.3.4.7 Concept sentinel_­for [iterator.concept.sentinel]")<I> S>
  constexpr I ranges::next(I x, iter_difference_t<I> n, S bound);
`

[4](#4)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iterators.tex#L3137)

*Effects*: Equivalent to: ranges​::​advance(x, n, bound); return x;
