[clang] a94e08d - [StaticAnalyzer] Fix non-virtual destructor warning

Jonas Devlieghere via cfe-commits cfe-commits at lists.llvm.org
Tue May 26 11:33:23 PDT 2020


Author: Jonas Devlieghere
Date: 2020-05-26T11:32:02-07:00
New Revision: a94e08d2e840a0e7ce032f59e9344bc49b5a54a1

URL: https://github.com/llvm/llvm-project/commit/a94e08d2e840a0e7ce032f59e9344bc49b5a54a1
DIFF: https://github.com/llvm/llvm-project/commit/a94e08d2e840a0e7ce032f59e9344bc49b5a54a1.diff

LOG: [StaticAnalyzer] Fix non-virtual destructor warning

Ficed warning: 'clang::ento::ExprEngine' has virtual functions but non-virtual destructor [-
Wnon-virtual-dtor]
  ~ExprEngine() = default;

Added: 
    

Modified: 
    clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h

Removed: 
    


################################################################################
diff  --git a/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h b/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h
index a94c847f35ee..b32302cfc337 100644
--- a/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h
+++ b/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h
@@ -177,7 +177,7 @@ class ExprEngine {
              SetOfConstDecls *VisitedCalleesIn,
              FunctionSummariesTy *FS, InliningModes HowToInlineIn);
 
-  ~ExprEngine() = default;
+  virtual ~ExprEngine() = default;
 
   /// Returns true if there is still simulation state on the worklist.
   bool ExecuteWorkList(const LocationContext *L, unsigned Steps = 150000) {


        


More information about the cfe-commits mailing list