1 // RUN: %clang_cc1 -triple x86_64-apple-macosx10.6 -fsyntax-only -fobjc-runtime-has-weak -fobjc-arc -x objective-c %s.result
2 // RUN: arcmt-test --args -triple x86_64-apple-macosx10.6 -fsyntax-only -fobjc-gc-only -x objective-c %s > %t
3 // RUN: diff %t %s.result
4 // RUN: arcmt-test --args -triple x86_64-apple-macosx10.6 -fsyntax-only -fobjc-gc-only -x objective-c++ %s > %t
5 // RUN: diff %t %s.result
7 // MRC __weak broke this test somehow.
13 void test1(CFTypeRef *cft) {
14 id x = NSMakeCollectable(cft);
33 @property (retain) id prop;
46 __attribute__((objc_arc_weak_reference_unavailable))
54 @property (assign) I3 *__weak pw1, *__weak pw2;
55 @property (assign) I3 *__strong ps;
56 @property (assign) I3 * pds;
62 @property (assign) I4Impl *__weak pw1, *__weak pw2;
63 @property (assign) I4Impl *__strong ps;
64 @property (assign) I4Impl * pds;
65 @property (assign) I4Impl * pds2;
68 @implementation I4Impl
69 @synthesize pw1, pw2, ps, pds, pds2;
71 -(void)test1:(CFTypeRef *)cft {
72 id x = NSMakeCollectable(cft);
79 @property (readonly) __weak id prop;