| Home | Libraries | People | FAQ | More

#### next

###### Description

Moves an iterator 1 position forwards.

###### Synopsis

    template<
        typename I
        >
    typename result_of::next<I>::type next(I const& i);

Table 1.2. Parameters

Parameter | Requirement | Description
--- | --- | ---
`i` | Model of Forward Iterator | Operation's argument

###### Expression Semantics

    next(i);

Return type: A model of the same iterator concept as `i`.

Semantics: Returns an iterator to the next element after `i`.

###### Header

    #include <boost/fusion/iterator/next.hpp>
    #include <boost/fusion/include/next.hpp>

###### Example

    typedef vector<int,int,int> vec;

    vec v(1,2,3);
    assert(deref(begin(v)) == 1);
    assert(deref(next(begin(v))) == 2);
    assert(deref(next(next(begin(v)))) == 3);