aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-03-13 22:00:25 +0000
committerChris Lattner <sabre@nondot.org>2009-03-13 22:00:25 +0000
commita66b4df9ea8beb965a27a938c349806f118f9722 (patch)
treeaf0dc9eb05fa1d897052cca4fc3ced6f95db30d8
parent7c175fb196a2bc3dbc86ea3865c713e1875f3f6d (diff)
add a testcase for recursion through blocks pointers, rdar://6676764.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66965 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--test/CodeGenObjC/blocks.m17
1 files changed, 17 insertions, 0 deletions
diff --git a/test/CodeGenObjC/blocks.m b/test/CodeGenObjC/blocks.m
new file mode 100644
index 0000000000..c32419e424
--- /dev/null
+++ b/test/CodeGenObjC/blocks.m
@@ -0,0 +1,17 @@
+// RUN: clang -emit-llvm -fblocks -S -o - %s
+// rdar://6676764
+
+struct S {
+ void (^F)(struct S*);
+} P;
+
+
+@interface T
+
+ - (int)foo: (T (^)(T*)) x;
+@end
+
+void foo(T *P) {
+ [P foo: 0];
+}
+