1 // RUN: %clang_cc1 -std=c++11 -emit-llvm %s -o - -triple=x86_64-pc-windows-msvc -mconstructor-aliases -fexceptions -fcxx-exceptions -fms-compatibility-version=18.00 | FileCheck -check-prefix=MSVC2013 -check-prefix=CHECK %s
2 // RUN: %clang_cc1 -std=c++11 -emit-llvm %s -o - -triple=x86_64-pc-windows-msvc -mconstructor-aliases -fexceptions -fcxx-exceptions -fms-compatibility-version=19.00 | FileCheck -check-prefix=MSVC2015 -check-prefix=CHECK %s
3 
4 void may_throw();
never_throws()5 void never_throws() noexcept(true) {
6   may_throw();
7 }
8 
9 // CHECK-LABEL: define dso_local void @"?never_throws@@YAXXZ"()
10 // CHECK-SAME:          personality i8* bitcast (i32 (...)* @__CxxFrameHandler3 to i8*)
11 // CHECK:      invoke void @"?may_throw@@YAXXZ"()
12 // CHECK:      %[[cp:.*]] = cleanuppad within none []
13 // MSVC2013:      call void @"?terminate@@YAXXZ"()
14 // MSVC2015:      call void @__std_terminate()
15 // CHECK-SAME:  [ "funclet"(token %[[cp]]) ]
16 // CHECK-NEXT: unreachable
17