diff options
Diffstat (limited to 'test/CodeGenCXX/windows-itanium-dllexport.cpp')
| -rw-r--r-- | test/CodeGenCXX/windows-itanium-dllexport.cpp | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/test/CodeGenCXX/windows-itanium-dllexport.cpp b/test/CodeGenCXX/windows-itanium-dllexport.cpp new file mode 100644 index 000000000000..92cca2444287 --- /dev/null +++ b/test/CodeGenCXX/windows-itanium-dllexport.cpp @@ -0,0 +1,30 @@ +// RUN: %clang_cc1 -emit-llvm -triple i686-windows-itanium -fdeclspec %s -o - | FileCheck %s + +struct __declspec(dllexport) s { + void f() {} +}; + +// CHECK: define {{.*}} dllexport {{.*}} @_ZN1saSERKS_ +// CHECK: define {{.*}} dllexport {{.*}} @_ZN1s1fEv + +template <class T> +class c { + void f() {} +}; + +template class __declspec(dllexport) c<int>; + +// CHECK: define {{.*}} dllexport {{.*}} @_ZN1cIiEaSERKS0_ +// CHECK: define {{.*}} dllexport {{.*}} @_ZN1cIiE1fEv + +extern template class c<char>; +template class __declspec(dllexport) c<char>; + +// CHECK: define {{.*}} dllexport {{.*}} @_ZN1cIcEaSERKS0_ +// CHECK: define {{.*}} dllexport {{.*}} @_ZN1cIcE1fEv + +c<double> g; +template class __declspec(dllexport) c<double>; + +// CHECK: define {{.*}} dllexport {{.*}} @_ZN1cIdEaSERKS0_ +// CHECK: define {{.*}} dllexport {{.*}} @_ZN1cIdE1fEv |
