C++ Template Metaprogramming
Solutions to the exercises throughout the book
Loading...
Searching...
No Matches
exercise_5_6::dimensions< T[N]> Struct Template Reference

Basically a tuple where the "head" is the value, and the rest is accessed by "tail". More...

#include <exercise-5-6.hpp>

Public Types

typedef dimensions< T[N]> type
 
typedef boost::mpl::if_< boost::is_array< T >, dimensions< T >, boost::mpl::void_ >::type tail
 The rest of the sequence.
 
typedef dimensions_tag tag
 

Static Public Attributes

static size_t const value = N
 

Detailed Description

template<typename T, size_t N>
struct exercise_5_6::dimensions< T[N]>

Basically a tuple where the "head" is the value, and the rest is accessed by "tail".

Definition at line 65 of file exercise-5-6.hpp.

Member Typedef Documentation

◆ tag

template<typename T , size_t N>
typedef dimensions_tag exercise_5_6::dimensions< T[N]>::tag

Definition at line 78 of file exercise-5-6.hpp.

◆ tail

template<typename T , size_t N>
typedef boost::mpl::if_<boost::is_array<T>,dimensions<T>,boost::mpl::void_>::type exercise_5_6::dimensions< T[N]>::tail

The rest of the sequence.

Definition at line 76 of file exercise-5-6.hpp.

◆ type

template<typename T , size_t N>
typedef dimensions<T[N]> exercise_5_6::dimensions< T[N]>::type

Definition at line 69 of file exercise-5-6.hpp.

Member Data Documentation

◆ value

template<typename T , size_t N>
size_t const exercise_5_6::dimensions< T[N]>::value = N
static

Definition at line 67 of file exercise-5-6.hpp.


The documentation for this struct was generated from the following file: