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

The MPL Reference Manual: is_sequence
Front Page / Sequences / Intrinsic Metafunctions / is_sequence

is_sequence

Synopsis

template<
      typename X
    >
struct is_sequence
{
    typedef unspecified type;
};

Description

Returns a boolean Integral Constant c such that c::value == true if and only if X is a model of Forward Sequence.

Parameters

Parameter Requirement Description
X Any type The type to query.

Expression semantics

typedef is_sequence<X>::type c;
Return type:

Boolean Integral Constant.

Semantics:

Equivalent to

typedef not_< is_same< begin<T>::type,void_ > >::type c;

Complexity

Amortized constant time.