blob: 2a5e0dca77049f6cd98d87c08a564ddd9ff46d81 [file] [log] [blame]
Patrick Beardb2f68202012-04-06 18:12:22 +00001// RUN: %clang_cc1 -x objective-c -fsyntax-only -verify -Wno-objc-root-class %s
2// RUN: %clang_cc1 -x objective-c++ -fsyntax-only -verify -Wno-objc-root-class %s
Fariborz Jahanianb5ea9db2011-12-20 22:21:08 +00003// rdar://10593227
4
5@class UIWindow;
6
7@interface CNAppDelegate
8
9@property (strong, nonatomic) UIWindow *window;
10
11@end
12
13
14@interface CNAppDelegate ()
15@property (nonatomic,retain) id foo;
16@end
17
18@implementation CNAppDelegate
19@synthesize foo;
20@synthesize window = _window;
21
22+(void)myClassMethod;
23{
24 foo = 0; // expected-error {{instance variable 'foo' accessed in class method}}
25}
26@end