[container.rev.reqmts] (original) (raw)

23 Containers library [containers]

23.2 Requirements [container.requirements]

23.2.2 General containers [container.requirements.general]

23.2.2.3 Reversible container requirements [container.rev.reqmts]

A type X meets the reversible container requirements ifX meets the container requirements, the iterator type of X belongs to the bidirectional or random access iterator categories ([iterator.requirements]), and the following types and expressions are well-formed and have the specified semantics.

typename X::reverse_iterator

Result: The type reverse_iterator<X​::​iterator>, an iterator type whose value type is T.

typename X::const_reverse_iterator

Result: The type reverse_iterator<X​::​const_iterator>, a constant iterator type whose value type is T.

Result: reverse_iterator;const_reverse_iterator for constant a.

Returns: reverse_iterator(end())

Result: reverse_iterator;const_reverse_iterator for constant a.

Returns: reverse_iterator(begin())

Result: const_reverse_iterator.

Returns: const_cast<X const&>(a).rbegin()

Result: const_reverse_iterator.

Returns: const_cast<X const&>(a).rend()