blob: e398ae549852314f1bf9c3aa19a3f8f4b19a8da2 [file] [log] [blame]
Fariborz Jahanian8e356bf2010-01-06 21:38:30 +00001// RUN: %clang_cc1 -fsyntax-only -verify %s
2// radar 7509234
3
4@protocol Foo
5@property (readonly, copy) id foos;
6@end
7
8@interface Bar <Foo> {
9}
10
11@end
12
13@interface Baz <Foo> {
14}
15@end
16
17@interface Bar ()
18@property (readwrite, copy) id foos;
19@end
20
21@interface Baz ()
22@property (readwrite, copy) id foos;
23@end
24
Fariborz Jahanian11ee2832011-09-24 00:56:59 +000025
26// rdar://10142679
27@class NSString;
28
29typedef struct {
30 float width;
31 float length;
32} NSRect;
33
34@interface MyClass {
35}
36@property (readonly) NSRect foo; // expected-note {{property declared here}}
37@property (readonly, strong) NSString *bar; // expected-note {{property declared here}}
38@end
39
40@interface MyClass ()
41@property (readwrite) NSString *foo; // expected-error {{type of property 'NSString *' in continuation class does not matchproperty type in primary class}}
42@property (readwrite, strong) NSRect bar; // expected-error {{type of property 'NSRect' in continuation class does not matchproperty type in primary class}}
43@end