aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/g++.dg/lto/20110311-1_0.C
blob: c63951e5bd8ae01efe0cf0259a86cc02056e186c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
/* { dg-lto-do link } */
/* { dg-extra-ld-options "-r -nostdlib" } */

struct NullType {};

template <class T, class U>
struct TList
{
    typedef T Head;
    typedef U Tail;
};

template <class T>
struct TListLength {};

template <class T, class U>
struct TListLength<TList<T,U> >
{
    enum
    {
        Ret = 1 + TListLength<U>::Ret
    };
};

template <>
struct TListLength<NullType>
{
    enum
    {
        Ret = 0
    };
};

template <class Moves>
class DDQMC
{
public:
    int* moves[TListLength<Moves>::Ret];
    inline DDQMC();
private:
};

template <class Moves>
DDQMC<Moves>::DDQMC()
{
}

int main()
{
    typedef DDQMC< TList<float, TList<int, NullType> > > mytype;
}