• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// RUN: %clang_cc1 -triple x86_64-apple-darwin11 -fsyntax-only -fobjc-arc -fblocks -verify -Wno-objc-root-class %s
2// expected-no-diagnostics
3// rdar://10156674
4
5@class NSArray;
6
7@interface MyClass2  {
8@private
9    NSArray *_names1;
10    NSArray *_names2;
11    NSArray *_names3;
12    NSArray *_names4;
13}
14@property (readwrite, strong) NSArray *names1; // <-- warning: Type of property....
15- (void)setNames1:(NSArray *)names;
16@property (readwrite, strong) __strong NSArray *names2; // <-- warning: Type of property....
17- (void)setNames2:(NSArray *)names;
18@property (readwrite, strong) __strong NSArray *names3; // <-- OK
19- (void)setNames3:(__strong NSArray *)names;
20@property (readwrite, strong) NSArray *names4; // <-- warning: Type of property....
21- (void)setNames4:(__strong NSArray *)names;
22
23@end
24
25@implementation MyClass2
26- (NSArray *)names1 { return _names1; }
27- (void)setNames1:(NSArray *)names {}
28- (NSArray *)names2 { return _names2; }
29- (void)setNames2:(NSArray *)names {}
30- (NSArray *)names3 { return _names3; }
31- (void)setNames3:(__strong NSArray *)names {}
32- (NSArray *)names4 { return _names4; }
33- (void)setNames4:(__strong NSArray *)names {}
34
35@end
36
37