Debian Codegraph @

clang/test/DebugInfo/ObjCXX/nested-ehlocation.mm

raw
1 // 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
2
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
7 void block(void (^)(void));
8 extern void foo();
9 struct A {
10 ~A(void) { foo(); }
11 void bar() const {}
12 };
13 void baz(void const *const) {}
14 struct B : A {};
15 void test() {
16 A a;
17 B b;
18 block(^(void) {
19 baz(&b);
20 block(^() {
21 a.bar();
22 });
23 });
24 }