aboutsummaryrefslogtreecommitdiff
path: root/lib/VMCore/ConstantFold.cpp
diff options
context:
space:
mode:
authorReid Spencer <rspencer@reidspencer.com>2005-04-24 22:27:20 +0000
committerReid Spencer <rspencer@reidspencer.com>2005-04-24 22:27:20 +0000
commit2b2a5283742662ddef1574b8278d5e8c8127badd (patch)
tree3f095f24bc4291a1ac111786938877c0d653388a /lib/VMCore/ConstantFold.cpp
parent628748650faa502b6c7d6615e94dc64255520069 (diff)
Shut GCC 4.0 up about classes with virtual functions but no virtual
destructor. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21510 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/ConstantFold.cpp')
-rw-r--r--lib/VMCore/ConstantFold.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/VMCore/ConstantFold.cpp b/lib/VMCore/ConstantFold.cpp
index 9ca8de302f..98fcf1a32e 100644
--- a/lib/VMCore/ConstantFold.cpp
+++ b/lib/VMCore/ConstantFold.cpp
@@ -30,6 +30,7 @@ using namespace llvm;
namespace {
struct ConstRules {
ConstRules() {}
+ virtual ~ConstRules() {}
// Binary Operators...
virtual Constant *add(const Constant *V1, const Constant *V2) const = 0;
@@ -86,6 +87,7 @@ namespace {
template<class ArgType, class SubClassName>
class TemplateRules : public ConstRules {
+
//===--------------------------------------------------------------------===//
// Redirecting functions that cast to the appropriate types
//===--------------------------------------------------------------------===//
@@ -202,6 +204,9 @@ class TemplateRules : public ConstRules {
static Constant *CastToDouble(const Constant *V) { return 0; }
static Constant *CastToPointer(const Constant *,
const PointerType *) {return 0;}
+
+public:
+ virtual ~TemplateRules() {}
};