Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for a snapshot of the master branch, built from commit 886930d6a2.
PrevUpHomeNext
value_at_c
Description

Returns the actual type at a given index from the Sequence.

Synopsis
template<
    typename Seq,
    int N>
struct value_at_c
{
    typedef unspecified type;
};

Table 1.31. Parameters

Parameter

Requirement

Description

Seq

A model of Random Access Sequence

Argument sequence

N

Positive integer index

Index of element


Expression Semantics
result_of::value_at_c<Seq, N>::type

Return type: Any type

Semantics: Returns the actual type at the Nth element of Seq.

Header
#include <boost/fusion/sequence/intrinsic/value_at.hpp>
#include <boost/fusion/include/value_at.hpp>
Example
typedef vector<int,float,char> vec;
BOOST_MPL_ASSERT((boost::is_same<result_of::value_at_c<vec, 1>::type, float>));

PrevUpHomeNext