2012-09-20 02:46:03 +08:00
|
|
|
// RUN: %clang_cc1 %s -triple x86_64-none-linux-gnu -emit-llvm -fcxx-exceptions -fexceptions -std=c++11 -o - | FileCheck %s
|
2012-08-02 08:10:24 +08:00
|
|
|
// PR13359
|
|
|
|
|
|
|
|
struct X {
|
|
|
|
~X();
|
|
|
|
};
|
|
|
|
struct Error {
|
|
|
|
Error(const X&) noexcept;
|
|
|
|
};
|
|
|
|
|
|
|
|
void f() {
|
|
|
|
try {
|
|
|
|
throw Error(X());
|
|
|
|
} catch (...) { }
|
|
|
|
}
|
|
|
|
|
|
|
|
// CHECK: define void @_Z1fv
|
|
|
|
// CHECK: call void @_ZN5ErrorC1ERK1X
|
|
|
|
// CHECK: invoke void @__cxa_throw
|
|
|
|
// CHECK: landingpad
|
|
|
|
// CHECK: call void @_ZN1XD1Ev
|
|
|
|
// CHECK-NOT: __cxa_free_exception
|