1 // { dg-do compile { target c++11 } }
2 // { dg-prune-output "note" }
3 // PR c++/33509
4 template<int M, int N> struct pair
5 {
6 int i, j;
pairpair7 pair() : i(M), j(N) {}
8 };
9
10 template<int... M> struct S
11 {
fooS12 template<int... N> static int foo() throw (pair <M, N>...) // { dg-error "mismatched" "" { target { ! c++17 } } }
13 { // { dg-error "dynamic exception specification" "" { target c++17 } .-1 }
14 return 1; // { dg-warning "deprecated" "" { target { ! c++17 } } .-2 }
15 }
16 };
17
bar()18 int bar ()
19 {
20 return S<0, 1, 2>::foo<0, 1, 3> ();
21 }
22
wibble()23 int wibble()
24 {
25 return S<0, 1, 2>::foo<0, 1> (); // { dg-error "no matching" "" { target { ! c++17 } } }
26 }
27