diff options
author | Pierre Habouzit <phabouzit@apple.com> | 2019-12-09 14:27:57 -0800 |
---|---|---|
committer | Alex Lorenz <arphaman@gmail.com> | 2019-12-09 14:30:01 -0800 |
commit | 1646bb86643326db6e220291d5c71c8d616f66fb (patch) | |
tree | df65e077974e2d9a067055888cab8e3dbd8d3d06 /clang/test/CodeGenObjC | |
parent | d5acc83a3ac3db85ca30b9e73b1bdb112f313d1b (diff) | |
download | bcm5719-llvm-1646bb86643326db6e220291d5c71c8d616f66fb.tar.gz bcm5719-llvm-1646bb86643326db6e220291d5c71c8d616f66fb.zip |
Also synthesize _cmd and self for properties
Patch by: Pierre Habouzit
Differential Revision: https://reviews.llvm.org/D71226
Diffstat (limited to 'clang/test/CodeGenObjC')
-rw-r--r-- | clang/test/CodeGenObjC/direct-method.m | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/clang/test/CodeGenObjC/direct-method.m b/clang/test/CodeGenObjC/direct-method.m index eb5a52eb11a..373bd22a84c 100644 --- a/clang/test/CodeGenObjC/direct-method.m +++ b/clang/test/CodeGenObjC/direct-method.m @@ -190,3 +190,14 @@ int useRoot(Root *r) { // CHECK: %{{[^ ]*}} = call i32 bitcast {{.*}} @"\01-[Root intProperty2]" return [r getInt] + [r intProperty] + [r intProperty2]; } + +__attribute__((objc_root_class)) +@interface RootDeclOnly +@property(direct, readonly) int intProperty; +@end + +int useRootDeclOnly(RootDeclOnly *r) { + // CHECK-LABEL: define i32 @useRootDeclOnly + // CHECK: %{{[^ ]*}} = call i32 bitcast {{.*}} @"\01-[RootDeclOnly intProperty]" + return [r intProperty]; +} |