1 /* Test instance variable visibility. */
2 /* Author: Dimitris Papavasiliou <dpapavas@gmail.com>. */
3 /* { dg-do compile } */
4 /* { dg-additional-options "-fivar-visibility=private" } */
7 @interface MySuperClass
13 @implementation MySuperClass
17 @interface MyClass : MySuperClass
20 @implementation MyClass
23 @interface MyOtherClass
24 - (void) test: (MyClass *) object;
27 @implementation MyOtherClass
28 - (void) test: (MyClass *) object
32 a = object->someivar; /* { dg-error "instance variable .someivar. is declared private" } */