blob: 24d7b05d7aa5f20a772da3d2ce1cebfbbf1a8ecb [file] [log] [blame]
John McCall260611a2012-06-20 06:18:46 +00001// RUN: %clang_cc1 -x objective-c++ -Wno-return-type -fblocks -fms-extensions -rewrite-objc -fobjc-runtime=macosx-fragile-10.5 %s -o %t-rw.cpp
Fariborz Jahanianec3683b2010-10-19 23:47:54 +00002// RUN: %clang_cc1 -fsyntax-only -fblocks -Wno-address-of-temporary -Did="void*" -D"SEL=void*" -D"__declspec(X)=" %t-rw.cpp
3// rdar:// 8570020
4
5@interface Foo {
6 Foo *foo;
7}
8
9@property (retain, nonatomic) Foo *foo;
10
11@end
12
13@implementation Foo
14
15- (Foo *)foo {
16 if (!foo) {
17 foo = 0;
18 }
19 return foo;
20}
21
22
23- (void) setFoo : (Foo *) arg {
24 foo = arg;
25}
26
27@synthesize foo;
28
29@end
30