2009-12-15 23:14:24 +03:00
|
|
|
// RUN: %clang_cc1 %s -emit-llvm -o - | FileCheck %s
|
2009-12-05 07:55:55 +03:00
|
|
|
|
|
|
|
template<class T> class A {
|
2010-04-09 23:03:51 +04:00
|
|
|
public:
|
2009-12-05 07:55:55 +03:00
|
|
|
A() {}
|
|
|
|
virtual void a() {}
|
|
|
|
};
|
|
|
|
class B : A<int> {
|
|
|
|
B();
|
|
|
|
};
|
|
|
|
B::B() {}
|
|
|
|
|
2010-08-03 11:24:12 +04:00
|
|
|
template class A<long>;
|
|
|
|
|
|
|
|
extern template class A<short>;
|
|
|
|
template class A<short>;
|
|
|
|
|
|
|
|
|
2011-01-24 03:46:19 +03:00
|
|
|
// CHECK: @_ZTV1B = linkonce_odr unnamed_addr constant
|
2011-01-12 00:10:26 +03:00
|
|
|
// CHECK: @_ZTV1AIlE = weak_odr unnamed_addr constant
|
|
|
|
// CHECK: @_ZTV1AIsE = weak_odr unnamed_addr constant
|
2011-01-24 03:46:19 +03:00
|
|
|
// CHECK: @_ZTV1AIiE = linkonce_odr unnamed_addr constant
|
2012-07-07 10:59:51 +04:00
|
|
|
|
|
|
|
template<class T> struct C {
|
|
|
|
virtual void c() {}
|
|
|
|
};
|
|
|
|
struct D : C<int> {
|
|
|
|
virtual void d();
|
|
|
|
};
|
|
|
|
void D::d() {}
|
|
|
|
|
|
|
|
// CHECK: define {{.*}}@_ZN1CIiE1cEv(
|