summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGenObjC
diff options
context:
space:
mode:
Diffstat (limited to 'clang/test/CodeGenObjC')
-rw-r--r--clang/test/CodeGenObjC/objc2-strong-cast-4.m23
1 files changed, 23 insertions, 0 deletions
diff --git a/clang/test/CodeGenObjC/objc2-strong-cast-4.m b/clang/test/CodeGenObjC/objc2-strong-cast-4.m
new file mode 100644
index 00000000000..e351f484770
--- /dev/null
+++ b/clang/test/CodeGenObjC/objc2-strong-cast-4.m
@@ -0,0 +1,23 @@
+// RUN: clang-cc -triple x86_64-apple-darwin10 -fobjc-gc -emit-llvm -o %t %s &&
+// RUN: grep objc_assign_strongCast %t | count 3 &&
+// RUN: true
+
+struct Slice {
+ void *__strong * items;
+};
+
+typedef struct Slice Slice;
+
+@interface ISlice {
+@public
+ void *__strong * items;
+}
+@end
+
+void foo () {
+ Slice *slice;
+ slice->items = 0;
+
+ ISlice *islice;
+ islice->items = 0;
+}
OpenPOWER on IntegriCloud