1 // RUN: clang-cc -triple i386-apple-darwin9 -fsyntax-only -verify %s
9 @property id prop_id; // expected-warning {{no 'assign', 'retain', or 'copy' attribute is specified - 'assign' is assumed}}, expected-warning {{default property attribute 'assign' not appropriate for non-gc object}}
18 @synthesize d1; // expected-error {{synthesized property 'd1' must either be named the same as}}
19 @dynamic bad; // expected-error {{property implementation must have its declaration in interface 'I'}}
20 @synthesize prop_id; // expected-error {{synthesized property 'prop_id' must either be named the same}} // expected-note {{previous declaration is here}}
21 @synthesize prop_id = IVAR; // expected-error {{type of property 'prop_id' does not match type of ivar 'IVAR'}} // expected-error {{property 'prop_id' is already implemented}}
22 @synthesize name; // OK! property with same name as an accessible ivar of same name
25 @implementation I(CAT)
26 @synthesize d1; // expected-error {{@synthesize not allowed in a category's implementation}}
27 @dynamic bad; // expected-error {{property implementation must have its declaration in the category 'CAT'}}
30 @implementation E // expected-warning {{cannot find interface declaration for 'E'}}
31 @dynamic d; // expected-error {{property implementation must have its declaration in interface 'E'}}
34 @implementation Q(MYCAT) // expected-error {{cannot find interface declaration for 'Q'}}
35 @dynamic d; // expected-error {{property implementation in a category with no category declaration}}
44 double bar = [foo bar];
49 typedef id BYObjectIdentifier;
53 @property(copy) BYObjectIdentifier identifier;