PR inline-asm/84742
[official-gcc.git] / gcc / testsuite / objc.dg / naming-6.m
blob86e58e087b4f7ce0bc1f103fd40687d4dd5fa43f
1 /* Testing for detecting duplicate ivars. */
2 /* { dg-do compile } */
4 @interface A 
6   /* TODO: Have the testsuite check that these messages occur only once!  */
7   char x; /* { dg-message "previous declaration" } */
8   char x; /* { dg-error "duplicate instance variable" } */
10 @end
12 /* In some versions of the compiler (eg, 4.6.x), having a subclass
13    would generate additional, duplicate errors for the duplicate
14    instance variable in the superclass, so adding the following would
15    cause the error messages above to be duplicated.  */
16 @interface B : A
18   char y;
20 @end