[cfe-commits] r173544 - [analyzer] Rename PruneNullReturnPaths to SuppressNullReturnPaths.

Jordan Rose jordan_rose at apple.com
Fri Jan 25 17:28:09 PST 2013


Author: jrose
Date: Fri Jan 25 19:28:09 2013
New Revision: 173544

URL: http://llvm.org/viewvc/llvm-project?rev=173544&view=rev
Log:
[analyzer] Rename PruneNullReturnPaths to SuppressNullReturnPaths.

"Prune" is the term for eliminating pieces of a path that are not
relevant to the user. "Suppress" means don't show that path at all.

Modified:
    cfe/trunk/include/clang/StaticAnalyzer/Core/AnalyzerOptions.h
    cfe/trunk/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp
    cfe/trunk/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp

Modified: cfe/trunk/include/clang/StaticAnalyzer/Core/AnalyzerOptions.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/StaticAnalyzer/Core/AnalyzerOptions.h?rev=173544&r1=173543&r2=173544&view=diff
==============================================================================
--- cfe/trunk/include/clang/StaticAnalyzer/Core/AnalyzerOptions.h (original)
+++ cfe/trunk/include/clang/StaticAnalyzer/Core/AnalyzerOptions.h Fri Jan 25 19:28:09 2013
@@ -211,12 +211,12 @@ private:
   // \sa getAlwaysInlineSize
   llvm::Optional<unsigned> AlwaysInlineSize;
 
-  /// \sa shouldPruneNullReturnPaths
-  llvm::Optional<bool> PruneNullReturnPaths;
+  /// \sa shouldSuppressNullReturnPaths
+  llvm::Optional<bool> SuppressNullReturnPaths;
 
   /// \sa shouldAvoidSuppressingNullArgumentPaths
   llvm::Optional<bool> AvoidSuppressingNullArgumentPaths;
-  
+
   /// \sa getGraphTrimInterval
   llvm::Optional<unsigned> GraphTrimInterval;
 
@@ -284,12 +284,12 @@ public:
   ///
   /// This is controlled by the 'suppress-null-return-paths' config option,
   /// which accepts the values "true" and "false".
-  bool shouldPruneNullReturnPaths();
+  bool shouldSuppressNullReturnPaths();
 
   /// Returns whether a bug report should \em not be suppressed if its path
   /// includes a call with a null argument, even if that call has a null return.
   ///
-  /// This option has no effect when #shouldPruneNullReturnPaths() is false.
+  /// This option has no effect when #shouldSuppressNullReturnPaths() is false.
   ///
   /// This is a counter-heuristic to avoid false negatives.
   ///

Modified: cfe/trunk/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp?rev=173544&r1=173543&r2=173544&view=diff
==============================================================================
--- cfe/trunk/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp (original)
+++ cfe/trunk/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp Fri Jan 25 19:28:09 2013
@@ -140,8 +140,8 @@ bool AnalyzerOptions::mayInlineObjCMetho
                           /* Default = */ true);
 }
 
-bool AnalyzerOptions::shouldPruneNullReturnPaths() {
-  return getBooleanOption(PruneNullReturnPaths,
+bool AnalyzerOptions::shouldSuppressNullReturnPaths() {
+  return getBooleanOption(SuppressNullReturnPaths,
                           "suppress-null-return-paths",
                           /* Default = */ true);
 }

Modified: cfe/trunk/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp?rev=173544&r1=173543&r2=173544&view=diff
==============================================================================
--- cfe/trunk/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp (original)
+++ cfe/trunk/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp Fri Jan 25 19:28:09 2013
@@ -251,7 +251,7 @@ public:
       // the report is resurrected as valid later on.
       ExprEngine &Eng = BRC.getBugReporter().getEngine();
       AnalyzerOptions &Options = Eng.getAnalysisManager().options;
-      if (Options.shouldPruneNullReturnPaths()) {
+      if (Options.shouldSuppressNullReturnPaths()) {
         if (hasCounterSuppression(Options))
           Mode = MaybeSuppress;
         else





More information about the cfe-commits mailing list