diff options
| author | Roman Divacky <rdivacky@FreeBSD.org> | 2010-05-27 15:17:06 +0000 |
|---|---|---|
| committer | Roman Divacky <rdivacky@FreeBSD.org> | 2010-05-27 15:17:06 +0000 |
| commit | d7279c4c177bca357ef96ff1379fd9bc420bfe83 (patch) | |
| tree | 3558f327a6f9ab59c5d7a06528d84e1560445247 /test/CodeGenCXX/key-function-vtable.cpp | |
| parent | be17651f5cd2e94922c1b732bc8589e180698193 (diff) | |
Notes
Diffstat (limited to 'test/CodeGenCXX/key-function-vtable.cpp')
| -rw-r--r-- | test/CodeGenCXX/key-function-vtable.cpp | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/test/CodeGenCXX/key-function-vtable.cpp b/test/CodeGenCXX/key-function-vtable.cpp index 251a14e28f2a..1cfeb0c5022d 100644 --- a/test/CodeGenCXX/key-function-vtable.cpp +++ b/test/CodeGenCXX/key-function-vtable.cpp @@ -32,11 +32,20 @@ namespace { } testg *testgvar = new testg; +struct X0 { virtual ~X0(); }; +struct X1 : X0 { + virtual void f(); +}; + +inline void X1::f() { } + +void use_X1(X1 *x1) { x1->f(); } + // FIXME: The checks are extremely difficult to get right when the globals // aren't alphabetized +// CHECK: @_ZTV2X1 = weak_odr constant // CHECK: @_ZTV5testa = constant [3 x i8*] [i8* null // CHECK: @_ZTV5testc = weak_odr constant [3 x i8*] [i8* null // CHECK: @_ZTVN12_GLOBAL__N_15testgE = internal constant [3 x i8*] [i8* null // CHECK: @_ZTV5teste = weak_odr constant [3 x i8*] [i8* null // CHECK: @_ZTV5testb = weak_odr constant [3 x i8*] [i8* null - |
