summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.jason/overload21.C
blob: 229be93da7cf34d952ad3f82a1b258ca9813cbd2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
// { dg-do assemble  }
struct X {
  void f (int = 4, char = 'r');	// { dg-error "previous specification" } 
  void g (int = 4, char = 'r');	// { dg-error "previous specification" } 
};

void
X::f (int i = 4, char x = 'r') // { dg-error "default argument" }
{ }

void
X::g (int i = 9, char x = 's') // { dg-error "default argument" }
{ }