[PATCH] D10023: Refactor: Simplify boolean conditional return statements in lib/StaticAnalyzer/Frontend

Richard via cfe-commits cfe-commits at lists.llvm.org
Sat Oct 24 10:37:54 PDT 2015


LegalizeAdulthood updated this revision to Diff 38312.
LegalizeAdulthood added a comment.

Update to latest.
This changeset needs reveiw; I am unsure of who to add as specific reviewers.


http://reviews.llvm.org/D10023

Files:
  lib/StaticAnalyzer/Frontend/CheckerRegistration.cpp

Index: lib/StaticAnalyzer/Frontend/CheckerRegistration.cpp
===================================================================
--- lib/StaticAnalyzer/Frontend/CheckerRegistration.cpp
+++ lib/StaticAnalyzer/Frontend/CheckerRegistration.cpp
@@ -83,10 +83,7 @@
 
   // For now, none of the static analyzer API is considered stable.
   // Versions must match exactly.
-  if (strcmp(versionString, CLANG_ANALYZER_API_VERSION_STRING) == 0)
-    return true;
-
-  return false;
+  return strcmp(versionString, CLANG_ANALYZER_API_VERSION_STRING) == 0;
 }
 
 void ClangCheckerRegistry::warnIncompatible(DiagnosticsEngine *diags,


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D10023.38312.patch
Type: text/x-patch
Size: 620 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20151024/a7d21682/attachment.bin>


More information about the cfe-commits mailing list