3rdParty/boost/1.78.0/libs/mpl/doc/refmanual/reverse.html
| Prev Next | Back Along | Up Home | Full TOC | Front Page / Algorithms / Transformation Algorithms / reverse |
template<
typename Sequence
, typename In =_unspecified_>
struct[reverse](./reverse.html){
typedef_unspecified_type;
};
Returns a reversed copy of the original sequence. reverse is a synonym for reverse_copy.
[Note: This wording applies to a no-inserter version(s) of the algorithm. See the Expression semantics subsection for a precise specification of the algorithm's details in all cases — end note]
#include <[boost/mpl/reverse.hpp](../../../../boost/mpl/reverse.hpp)>
| Parameter | Requirement | Description |
|---|---|---|
| Sequence | Forward Sequence | A sequence to reverse. |
| In | Inserter | An inserter. |
For any Forward Sequence s, and an Inserter in:
typedef[reverse](./reverse.html)<s,in>::type r;
| Return type: |
A type.
| | Semantics: |
Equivalent to
typedef[reverse\_copy](./reverse-copy.html)<s,in>::type r;
|
Linear.
typedef[vector\_c](./vector-c.html)<int,9,8,7,6,5,4,3,2,1,0> numbers;
typedef[reverse](./reverse.html)< numbers >::type result;[BOOST\_MPL\_ASSERT](./assert.html)(([equal](./equal.html)< result,[range\_c](./range-c.html)<int,0,10> > ));
Transformation Algorithms, Reversible Algorithm, reverse_copy, copy, copy_if
| Prev Next | Back Along | Up Home | Full TOC |
Copyright © 2001-2009 Aleksey Gurtovoy and David Abrahams Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) |