1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
#include "TypeList.hpp" #include <iostream> using namespace std; typedef TypeList< int, TypeList< char *, TypeList< int, NullType > > > TestType; typedef TYPELIST_3( int, char *, int ) TestType2; int len = Length<TestType2>::value; int main( void ) { cout << "len: " << len << endl; return 0; }