Debian Codegraph @

gcc/testsuite/g++.dg/cpp0x/variadic141.C

raw
1 // Origin: PR c++/53609
2 // { dg-do compile { target c++11 } }
3
4 template<class...I> struct List{ static const bool is_ok = false;};
5 template<int T> struct Z
6 {
7 static const int value = T;
8 static const int value_square = T * T;
9 };
10
11 template<template<int> class U>
12 struct List<U<2>, U<3>, U<4>, U<9>> { static const bool is_ok = true;};
13
14 template<int...T> using LZ = List<Z<T>...>;
15
16 template<class...T>
17 struct F
18 {
19 using N = LZ<T::value..., Z<4>::value, Z<9>::value>;
20 };
21
22 static_assert (F<Z<2>, Z<3>>::N::is_ok, "");