PR c++/85553
[official-gcc.git] / gcc / testsuite / g++.dg / cpp0x / variadic116.C
blob05a9a79f4fa828ad57ee6917427d1a91b1c724bd
1 // Origin: PR c++/48320
2 // { dg-do compile { target c++11 } }
4 template<class... T>
5 struct tuple
7     typedef int type;
8 };
10 template<int... Indices>
11 struct indices
15 template<unsigned i, class Tuple>
16 struct tuple_element
18     typedef Tuple type;
21 template<class Tuple,
22          int... Indices,
23          class Result = tuple<typename tuple_element<Indices, Tuple>::type...> >
24 Result
25 f(Tuple&&, indices<Indices...>);
28 void
29 foo()
31     f(tuple<int, char, unsigned> (), indices<2, 1, 0> ());