summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGenObjC/blocks-ivar-debug.m
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2010-05-10 17:24:58 +0000
committerDevang Patel <dpatel@apple.com>2010-05-10 17:24:58 +0000
commitb319adec49d7b2af0113dc323ce7bf5c23967df8 (patch)
treead26bb2cf89deaa3459e1383c7598cc2693ceaa0 /clang/test/CodeGenObjC/blocks-ivar-debug.m
parent01fcdaa7f5329ee88e59f6e7d7e152436f68b306 (diff)
downloadbcm5719-llvm-b319adec49d7b2af0113dc323ce7bf5c23967df8.tar.gz
bcm5719-llvm-b319adec49d7b2af0113dc323ce7bf5c23967df8.zip
If variable location is invalid then use current location.
This fixes radar 7959934. llvm-svn: 103408
Diffstat (limited to 'clang/test/CodeGenObjC/blocks-ivar-debug.m')
-rw-r--r--clang/test/CodeGenObjC/blocks-ivar-debug.m20
1 files changed, 20 insertions, 0 deletions
diff --git a/clang/test/CodeGenObjC/blocks-ivar-debug.m b/clang/test/CodeGenObjC/blocks-ivar-debug.m
new file mode 100644
index 00000000000..92a5a72d42e
--- /dev/null
+++ b/clang/test/CodeGenObjC/blocks-ivar-debug.m
@@ -0,0 +1,20 @@
+// RUN: %clang_cc1 -g %s -fblocks -S -o /dev/null
+// Radar 7959934
+
+@interface NSObject {
+ struct objc_object *isa;
+}
+@end
+@interface Foo : NSObject {
+ int _prop;
+}
+@end
+
+@implementation Foo
+- (int)doSomething {
+ int (^blk)(void) = ^{ return _prop; };
+ return blk();
+}
+
+@end
+
OpenPOWER on IntegriCloud