summaryrefslogtreecommitdiffstats
path: root/clang/lib/Analysis
diff options
context:
space:
mode:
authorKristof Umann <kristof.umann@ericsson.com>2019-09-12 19:09:24 +0000
committerKristof Umann <kristof.umann@ericsson.com>2019-09-12 19:09:24 +0000
commit72649423c043341c770516cd73aecde281730260 (patch)
tree9dc15e1f887b38ebfb964737cba930ec5e80c141 /clang/lib/Analysis
parent456bfdf5154b05b3b7aefbe8bd360d673feb6a82 (diff)
downloadbcm5719-llvm-72649423c043341c770516cd73aecde281730260.tar.gz
bcm5719-llvm-72649423c043341c770516cd73aecde281730260.zip
[analyzer][NFC] Fix inconsistent references to checkers as "checks"
Traditionally, clang-tidy uses the term check, and the analyzer uses checker, but in the very early years, this wasn't the case, and code originating from the early 2010's still incorrectly refer to checkers as checks. This patch attempts to hunt down most of these, aiming to refer to checkers as checkers, but preserve references to callback functions (like checkPreCall) as checks. Differential Revision: https://reviews.llvm.org/D67140 llvm-svn: 371760
Diffstat (limited to 'clang/lib/Analysis')
-rw-r--r--clang/lib/Analysis/PathDiagnostic.cpp4
-rw-r--r--clang/lib/Analysis/plugins/SampleAnalyzer/MainCallChecker.cpp2
2 files changed, 3 insertions, 3 deletions
diff --git a/clang/lib/Analysis/PathDiagnostic.cpp b/clang/lib/Analysis/PathDiagnostic.cpp
index 33cb813b195..764cb8ed0e4 100644
--- a/clang/lib/Analysis/PathDiagnostic.cpp
+++ b/clang/lib/Analysis/PathDiagnostic.cpp
@@ -117,11 +117,11 @@ void PathPieces::flattenTo(PathPieces &Primary, PathPieces &Current,
PathDiagnostic::~PathDiagnostic() = default;
PathDiagnostic::PathDiagnostic(
- StringRef CheckName, const Decl *declWithIssue, StringRef bugtype,
+ StringRef CheckerName, const Decl *declWithIssue, StringRef bugtype,
StringRef verboseDesc, StringRef shortDesc, StringRef category,
PathDiagnosticLocation LocationToUnique, const Decl *DeclToUnique,
std::unique_ptr<FilesToLineNumsMap> ExecutedLines)
- : CheckName(CheckName), DeclWithIssue(declWithIssue),
+ : CheckerName(CheckerName), DeclWithIssue(declWithIssue),
BugType(StripTrailingDots(bugtype)),
VerboseDesc(StripTrailingDots(verboseDesc)),
ShortDesc(StripTrailingDots(shortDesc)),
diff --git a/clang/lib/Analysis/plugins/SampleAnalyzer/MainCallChecker.cpp b/clang/lib/Analysis/plugins/SampleAnalyzer/MainCallChecker.cpp
index abf8329cddf..fd210d733fd 100644
--- a/clang/lib/Analysis/plugins/SampleAnalyzer/MainCallChecker.cpp
+++ b/clang/lib/Analysis/plugins/SampleAnalyzer/MainCallChecker.cpp
@@ -37,7 +37,7 @@ void MainCallChecker::checkPreStmt(const CallExpr *CE,
BT.reset(new BugType(this, "call to main", "example analyzer plugin"));
auto report =
- std::make_unique<PathSensitiveBugReport>(*BT, BT->getName(), N);
+ std::make_unique<PathSensitiveBugReport>(*BT, BT->getDescription(), N);
report->addRange(Callee->getSourceRange());
C.emitReport(std::move(report));
}
OpenPOWER on IntegriCloud