diff options
author | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2011-11-07 18:46:46 +0000 |
---|---|---|
committer | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2011-11-07 18:46:46 +0000 |
commit | b0e1e121b32a9a04b39f1b77b3068bce2f3be05a (patch) | |
tree | 3c37fc42b2dcb5f13a17e6659028d7c19665333e /test/ARCMT | |
parent | bf8455c56cc5e328c31a2b56f5587cd0873ba0ae (diff) |
[arcmt] In GC, handle (assign) @properties.
-Move __strong/__weak added to a property type to the property attribute,
e.g. "@property (assign) __weak Foo *prop;" --> "@property (weak) Foo *prop;"
-Remove (assign) in a property so that it becomes strong-by-default in ARC.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143979 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/ARCMT')
-rw-r--r-- | test/ARCMT/GC.m | 19 | ||||
-rw-r--r-- | test/ARCMT/GC.m.result | 19 |
2 files changed, 38 insertions, 0 deletions
diff --git a/test/ARCMT/GC.m b/test/ARCMT/GC.m index b3ba2a4211..e49bca8fa3 100644 --- a/test/ARCMT/GC.m +++ b/test/ARCMT/GC.m @@ -48,3 +48,22 @@ __attribute__((objc_arc_weak_reference_unavailable)) __weak QQ *q; } @end + +@interface I3 +@property (assign) I3 *__weak pw1, *__weak pw2; +@property (assign) I3 *__strong ps; +@property (assign) I3 * pds; +@end + +@interface I4Impl { + I4Impl *pds2; +} +@property (assign) I4Impl *__weak pw1, *__weak pw2; +@property (assign) I4Impl *__strong ps; +@property (assign) I4Impl * pds; +@property (assign) I4Impl * pds2; +@end + +@implementation I4Impl +@synthesize pw1, pw2, ps, pds, pds2; +@end diff --git a/test/ARCMT/GC.m.result b/test/ARCMT/GC.m.result index 405219ff3a..67a70e3dd2 100644 --- a/test/ARCMT/GC.m.result +++ b/test/ARCMT/GC.m.result @@ -43,3 +43,22 @@ __attribute__((objc_arc_weak_reference_unavailable)) __unsafe_unretained QQ *q; } @end + +@interface I3 +@property (weak) I3 * pw1, * pw2; +@property (strong) I3 * ps; +@property (assign) I3 * pds; +@end + +@interface I4Impl { + I4Impl *pds2; +} +@property (weak) I4Impl * pw1, * pw2; +@property I4Impl * ps; +@property I4Impl * pds; +@property I4Impl * pds2; +@end + +@implementation I4Impl +@synthesize pw1, pw2, ps, pds, pds2; +@end |