2 // { dg-do compile { target c++11 } }
4 typedef decltype(sizeof(int)) size_t;
6 template <typename...Ts>
12 template <unsigned...Ts>
13 using size_for = size<sizeof...(Ts)>;
15 template<class T, class U> struct assert_same;
16 template<class T> struct assert_same<T,T> {};
18 template <typename T, unsigned...Ts>
19 using wrapped = list<T, size_for<0, Ts...>>;
21 // This assertion fails (produces size<4>)
24 wrapped<float,2,3,4,5>> a3;
27 template <typename T, unsigned...Ts>
28 using wrapped2 = list<T, size_for<Ts..., 0>>;
30 // This assertion fails (produces size<2>)
33 wrapped2<float,2,3,4,5>> a4;