1 // RUN: %clang_cc1 %s -fexceptions -fseh-exceptions -emit-llvm -triple x86_64-w64-windows-gnu -o - | FileCheck %s
2 
3 extern "C" void foo();
4 extern "C" void bar();
5 
6 struct Cleanup {
7   ~Cleanup() {
8     bar();
9   }
10 };
11 
12 extern "C" void test() {
13   Cleanup x;
14   foo();
15 }
16 
17 // CHECK: define void @test()
18 // CHECK: invoke void @foo()
19 // CHECK: landingpad { i8*, i32 } personality i8* bitcast (i32 (...)* @__gxx_personality_seh0 to i8*)
20