diff options
-rw-r--r-- | include/llvm/Pass.h | 2 | ||||
-rw-r--r-- | lib/VMCore/Pass.cpp | 5 |
2 files changed, 6 insertions, 1 deletions
diff --git a/include/llvm/Pass.h b/include/llvm/Pass.h index 84ec8442fb..1ab6ff9a72 100644 --- a/include/llvm/Pass.h +++ b/include/llvm/Pass.h @@ -88,7 +88,7 @@ class Pass { Pass(const Pass &); // DO NOT IMPLEMENT public: Pass() : Resolver(0), PassInfoCache(0) {} - virtual ~Pass() { delete Resolver; } // Destructor is virtual so we can be subclassed + virtual ~Pass(); /// getPassName - Return a nice clean name for a pass. This usually /// implemented in terms of the name that is registered by one of the diff --git a/lib/VMCore/Pass.cpp b/lib/VMCore/Pass.cpp index be49ae41a1..e6b31b302a 100644 --- a/lib/VMCore/Pass.cpp +++ b/lib/VMCore/Pass.cpp @@ -28,6 +28,11 @@ using namespace llvm; // // Force out-of-line virtual method. +Pass::~Pass() { + delete Resolver; +} + +// Force out-of-line virtual method. ModulePass::~ModulePass() { } bool Pass::mustPreserveAnalysisID(const PassInfo *AnalysisID) const { |