aboutsummaryrefslogtreecommitdiff
path: root/test/CodeGenCXX/virtual-destructor-synthesis.cpp
diff options
context:
space:
mode:
authorFariborz Jahanian <fjahanian@apple.com>2009-12-01 23:18:25 +0000
committerFariborz Jahanian <fjahanian@apple.com>2009-12-01 23:18:25 +0000
commit6bc9768408d4b45e00350018b6e3540bc05d267d (patch)
tree398e9f5f468f660922b527b95e0ff5e363ef312c /test/CodeGenCXX/virtual-destructor-synthesis.cpp
parentfbcc7bed1a0661ecc91b62e0696b8310887713f6 (diff)
Fix a code gen. crash synthesizing a destructor.
Fixes pr5660. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90283 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGenCXX/virtual-destructor-synthesis.cpp')
-rw-r--r--test/CodeGenCXX/virtual-destructor-synthesis.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/test/CodeGenCXX/virtual-destructor-synthesis.cpp b/test/CodeGenCXX/virtual-destructor-synthesis.cpp
new file mode 100644
index 0000000000..b95218a322
--- /dev/null
+++ b/test/CodeGenCXX/virtual-destructor-synthesis.cpp
@@ -0,0 +1,16 @@
+// RUN: clang-cc %s -emit-llvm -o - | FileCheck %s
+
+struct box {
+ virtual ~box();
+};
+
+struct pile_box : public box {
+ pile_box(box *);
+};
+
+pile_box::pile_box(box *pp)
+{
+}
+
+// CHECK: call void @_ZdlPv
+