OSDN Git Service

In gcc/:
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / objc.dg / property / dynamic-1.m
1 /* { dg-do compile } */
2
3 #include <objc/objc.h>
4
5 @interface MyRootClass
6 {
7   Class isa;
8 }
9 @end
10
11 @implementation MyRootClass
12 @end
13
14 @dynamic isa;           /* { dg-error ".@dynamic. not in @implementation context" } */
15
16 @interface Test : MyRootClass
17 {
18   int v1;
19   int v2;
20   int v3;
21   int v4;
22 }
23 @end
24
25 @implementation Test
26 @dynamic;            /* { dg-error "expected identifier" } */
27 @dynamic v1, ;       /* { dg-error "expected identifier" } */
28 @dynamic v1, v2, v3; /* { dg-error ".@dynamic. is not supported in this version of the compiler" } */
29 @dynamic v4;         /* { dg-error ".@dynamic. is not supported in this version of the compiler" } */
30 @end