aboutsummaryrefslogtreecommitdiff
path: root/test/CodeGenObjC/objc2-write-barrier-5.m
diff options
context:
space:
mode:
Diffstat (limited to 'test/CodeGenObjC/objc2-write-barrier-5.m')
-rw-r--r--test/CodeGenObjC/objc2-write-barrier-5.m25
1 files changed, 21 insertions, 4 deletions
diff --git a/test/CodeGenObjC/objc2-write-barrier-5.m b/test/CodeGenObjC/objc2-write-barrier-5.m
index 373df0cc16b9..122fa9f3c0b7 100644
--- a/test/CodeGenObjC/objc2-write-barrier-5.m
+++ b/test/CodeGenObjC/objc2-write-barrier-5.m
@@ -1,9 +1,9 @@
-// RUN: %clang_cc1 -triple x86_64-apple-darwin10 -fobjc-gc -emit-llvm -o %t %s
+// RUN: %clang_cc1 -triple x86_64-apple-darwin10 -fobjc-fragile-abi -fobjc-gc -emit-llvm -o %t %s
// RUN: grep objc_assign_ivar %t | count 0
-// RUN: grep objc_assign_strongCast %t | count 5
-// RUN: %clang_cc1 -x objective-c++ -triple x86_64-apple-darwin10 -fobjc-gc -emit-llvm -o %t %s
+// RUN: grep objc_assign_strongCast %t | count 8
+// RUN: %clang_cc1 -x objective-c++ -triple x86_64-apple-darwin10 -fobjc-fragile-abi -fobjc-gc -emit-llvm -o %t %s
// RUN: grep objc_assign_ivar %t | count 0
-// RUN: grep objc_assign_strongCast %t | count 5
+// RUN: grep objc_assign_strongCast %t | count 8
@interface TestUnarchiver
{
@@ -27,3 +27,20 @@ struct unarchive_list {
}
@end
+
+// rdar://10191569
+@interface I
+{
+ struct S {
+ id _timer;
+ } *p_animationState;
+}
+@end
+
+@implementation I
+- (void) Meth {
+ p_animationState->_timer = 0;
+ (*p_animationState)._timer = 0;
+ (&(*p_animationState))->_timer = 0;
+}
+@end