OSDN Git Service

PR c++/4872
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.old-deja / g++.law / visibility11.C
1 // Build don't link: 
2 // Special g++ Options: -w
3 // GROUPS passed visibility
4 // visibility file
5 // From: Alan Shepherd <a.shepherd@nexor.co.uk>
6 // Date:     Tue, 22 Jun 1993 14:53:23 +0100
7 // Subject:  bug with MI in gcc-2.4.5
8 // Message-ID: <9659.740757203@nexor.co.uk>
9
10 class A
11 {
12     int a;
13
14 protected:
15
16     virtual void State(int b)   { a = b; }
17
18 };
19
20 class B : public A
21 {
22     char* foo;
23
24 public:
25
26     B(const char*);
27 };
28
29 class C : public A
30 {
31     char* foo2;
32
33 public:
34
35     C(const char*);
36 };
37
38 class D : public B, public C
39 {
40 public:
41   D();
42 protected:
43
44     virtual void State(int a)
45     {
46         B::State(a);
47         C::State(a);
48     }
49 };
50
51
52