gcc/testsuite/g++.dg/cpp0x/variadic125.C
raw| 1 | // PR c++/52380 |
| 2 | // { dg-do compile { target c++11 } } |
| 3 | |
| 4 | template<typename T> |
| 5 | struct S |
| 6 | { |
| 7 | template<typename U> |
| 8 | struct Unary // Line 5 |
| 9 | {}; |
| 10 | |
| 11 | template<unsigned, typename... Args> |
| 12 | struct Dispatch // Line 9 |
| 13 | : public Unary<Args...> |
| 14 | {}; |
| 15 | |
| 16 | template<typename... Args> |
| 17 | struct Variadic |
| 18 | : public Dispatch<sizeof...(Args), Args...> |
| 19 | {}; |
| 20 | }; |
| 21 | |
| 22 | int main() |
| 23 | { |
| 24 | S<void>::Variadic<void> z; |
| 25 | } |