[clang] 848be08 - [StaticAnalyzer] Modernize DeleteBugVisitor (NFC)

Kazu Hirata via cfe-commits cfe-commits at lists.llvm.org
Sun Aug 20 22:08:15 PDT 2023


Author: Kazu Hirata
Date: 2023-08-20T22:08:02-07:00
New Revision: 848be088658da0d07680e129a6a7f79a7f31d2f3

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

LOG: [StaticAnalyzer] Modernize DeleteBugVisitor (NFC)

Added: 
    

Modified: 
    clang/lib/StaticAnalyzer/Checkers/DeleteWithNonVirtualDtorChecker.cpp

Removed: 
    


################################################################################
diff  --git a/clang/lib/StaticAnalyzer/Checkers/DeleteWithNonVirtualDtorChecker.cpp b/clang/lib/StaticAnalyzer/Checkers/DeleteWithNonVirtualDtorChecker.cpp
index 7c583376200803..3c142b49ff7288 100644
--- a/clang/lib/StaticAnalyzer/Checkers/DeleteWithNonVirtualDtorChecker.cpp
+++ b/clang/lib/StaticAnalyzer/Checkers/DeleteWithNonVirtualDtorChecker.cpp
@@ -40,7 +40,7 @@ class DeleteWithNonVirtualDtorChecker
 
   class DeleteBugVisitor : public BugReporterVisitor {
   public:
-    DeleteBugVisitor() : Satisfied(false) {}
+    DeleteBugVisitor() = default;
     void Profile(llvm::FoldingSetNodeID &ID) const override {
       static int X = 0;
       ID.AddPointer(&X);
@@ -50,7 +50,7 @@ class DeleteWithNonVirtualDtorChecker
                                      PathSensitiveBugReport &BR) override;
 
   private:
-    bool Satisfied;
+    bool Satisfied = false;
   };
 
 public:


        


More information about the cfe-commits mailing list