view gcc/testsuite/g++.dg/cpp0x/vt-51314.C @ 131:84e7813d76e9

gcc-8.2
author mir3636
date Thu, 25 Oct 2018 07:37:49 +0900
parents 04ced10e8804
children
line wrap: on
line source

// { dg-do compile { target c++11 } }
// { dg-prune-output "invalid" }

template<int>struct A{};
template<class...U>void f(U...){
    A<sizeof...U> x; // { dg-error "surrounded by parentheses" }
}


template<int...> struct Indices;
template<class> struct Next_increasing_indices;
template<int...I> struct Next_increasing_indices<Indices<I...> > {
    typedef Indices<I...,sizeof...I> type; // { dg-error "surrounded by parentheses" }
};