blob: 030bc7c5cd3e488a74e3f8a5be53e12e9a23d03c [file] [log] [blame]
Douglas Katzman3459ce22015-10-08 04:24:12 +00001// RUN: %clang_cc1 -triple x86_64-apple-macosx -emit-llvm -debug-info-kind=limited -stdlib=libc++ -fblocks -fexceptions -x objective-c++ -o - %s | FileCheck %s
Adrian Prantl39428e72015-02-03 18:40:42 +00002
3// Verify that all invoke instructions have a debug location.
4// Literally: There are no unwind lines that don't end with ", (!dbg 123)".
5// CHECK-NOT: {{to label %.* unwind label [^,]+$}}
6
7void block(void (^)(void));
8extern void foo();
9struct A {
10 ~A(void) { foo(); }
11 void bar() const {}
12};
13void baz(void const *const) {}
14struct B : A {};
15void test() {
16 A a;
17 B b;
18 block(^(void) {
19 baz(&b);
20 block(^() {
21 a.bar();
22 });
23 });
24}