summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.jason/access16.C
blob: 4eb499b639fea1a866de5696f74a474c80730dd6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
// { dg-do assemble  }
// Bug: g++ uses the same binfo for the a subobject of c and the a subobject
// of b, so basetype_paths get bashed improperly.

class a {
protected:
	virtual void foo() { }	// { dg-bogus "" } 
};

class b : public virtual a {};

class c : public b {
public:
	void bar() { b::foo(); } // { dg-bogus "" } 
};

int main() {
	c test;
	test.bar();
}