| 1 |
// PR c++/94100 |
| 2 |
// { dg-do compile { target c++11 } } |
| 3 |
|
| 4 |
template <typename... T> struct ValListWithTypes { |
| 5 |
template <T... Members> struct WithVals { |
| 6 |
using TypeList = ValListWithTypes; |
| 7 |
}; |
| 8 |
}; |
| 9 |
|
| 10 |
template <typename ValList, typename ValTypeList = typename ValList::TypeList> |
| 11 |
struct Widget; |
| 12 |
|
| 13 |
template <typename ValList, typename... ValTypes> |
| 14 |
struct Widget<ValList, ValListWithTypes<ValTypes...>> { |
| 15 |
template <typename = ValList> struct Impl {}; |
| 16 |
}; |
| 17 |
|
| 18 |
template <typename ValList, typename... ValTypes> |
| 19 |
template <ValTypes... Vals> |
| 20 |
struct Widget<ValList, ValListWithTypes<ValTypes...>>::Impl< |
| 21 |
typename ValListWithTypes<ValTypes...>::template WithVals<Vals...>> {}; |
| 22 |
|
| 23 |
int main(void) { Widget<ValListWithTypes<int>::WithVals<0>>::Impl<> impl; } |