A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://timsong-cpp.github.io/cppwp/n4659/bidirectional.iterators below:

[bidirectional.iterators]

27 Iterators library [iterators] 27.2 Iterator requirements [iterator.requirements] 27.2.6 Bidirectional iterators [bidirectional.iterators]

A class or pointer type X satisfies the requirements of a bidirectional iterator if, in addition to satisfying the requirements for forward iterators, the following expressions are valid as shown in Table 98.

Table

98

— Bidirectional iterator requirements (in addition to forward iterator)


Expression Return type Operational Assertion/note semantics pre-/post-condition --r X& Requires: there exists s such that r == ++s.
Postconditions: r is dereferenceable.
--(++r) == r.
--r == --s implies r == s.
&r == &--r. r-- convertible to const X& { X tmp = r;
--r;
return tmp; } *r-- reference

[Note: Bidirectional iterators allow algorithms to move iterators backward as well as forward. end note]


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4