brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.3 KiB · 95b7b3a Raw
47 lines · cpp
1// RUN: %clang_cc1 -triple i686-windows-itanium -fdeclspec -fcxx-exceptions -emit-llvm %s -o - | FileCheck %s2// RUN: %clang_cc1 -triple i686-windows-itanium -fdeclspec -fcxx-exceptions -fno-rtti -emit-llvm %s -o - | FileCheck %s -check-prefix CHECK-EH-IMPORT3 4namespace __cxxabiv1 {5class __declspec(dllexport) __fundamental_type_info {6public:7  virtual ~__fundamental_type_info();8};9 10__fundamental_type_info::~__fundamental_type_info() {}11}12 13struct __declspec(dllimport) base {14  virtual void method();15};16struct __declspec(dllexport) derived : base {17  virtual ~derived();18};19derived::~derived() {20  method();21}22 23void f() {24  throw base();25}26 27// CHECK-DAG: @_ZTIi = dso_local dllexport constant28// CHECK-DAG: @_ZTSi = dso_local dllexport constant29 30// CHECK-DAG: @_ZTI7derived = dso_local dllexport constant31// CHECK-DAG: @_ZTS7derived = dso_local dllexport constant32// CHECK-DAG: @_ZTV7derived = dso_local dllexport unnamed_addr constant33 34// CHECK-DAG: @_ZTI4base = external dllimport constant35 36// CHECK-EH-IMPORT: @_ZTI4base = linkonce_odr dso_local constant37// CHECK-EH-IMPORT: @_ZTS4base = linkonce_odr dso_local constant38 39struct __declspec(dllimport) gatekeeper {};40struct zuul : gatekeeper {41  virtual ~zuul();42};43zuul::~zuul() {}44 45// CHECK-DAG: @_ZTI10gatekeeper = linkonce_odr dso_local constant46// CHECK-DAG: @_ZTS10gatekeeper = linkonce_odr dso_local constant47