Debian Codegraph @

gcc/testsuite/g++.dg/tc1/dr217-2.C

raw
1 // { dg-do compile }
2 // DR217: Default arguments for non-template member functions of class
3 // templates
4
5 template <class T>
6 struct S
7 {
8 static void foo (int);
9 };
10
11 template <class T>
12 void S<T>::foo (int = 0) // { dg-error "" "default arguments for parameters of member functions of class templates can be specified in the initial declaration only" }
13 { }