1// Test that access control for types and statics works properly
2// with nested types.
3
4// Build don't link:
5
6class A {
7  static int I1;		// ERROR - private
8  struct B1 { };		// ERROR - private
9public:
10  static int I2;
11  struct B2 { };
12};
13
14class D: public A {
15  struct E {
16    void f ();
17  };
18};
19
20void D::E::f ()
21{
22  int i = I1;			// ERROR - within this context
23  B1 b1;			// ERROR - within this context
24  i = I2;
25  B2 b2;
26}
27
28void f ()
29{
30  A::B1 b1;			// ERROR - within this context
31  new A::B1;			// ERROR - within this context
32  (A::B1) b1;			// ERROR - within this context
33}
34