summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenAction.cpp
diff options
context:
space:
mode:
authorAdam Nemet <anemet@apple.com>2017-09-19 17:59:40 +0000
committerAdam Nemet <anemet@apple.com>2017-09-19 17:59:40 +0000
commit5d2eb16c9f0558e2f0d108949a6a12c4e4f01cde (patch)
tree6424f8097183803a087a442a839bfbdc4f55bf49 /clang/lib/CodeGen/CodeGenAction.cpp
parentd327254b1b224091cba169811ec4b6fe31c830e2 (diff)
downloadbcm5719-llvm-5d2eb16c9f0558e2f0d108949a6a12c4e4f01cde.tar.gz
bcm5719-llvm-5d2eb16c9f0558e2f0d108949a6a12c4e4f01cde.zip
Fix ClangDiagnosticHandler::is*RemarkEnabled members
Apparently these weren't really working. I added test coverage and fixed the typo in the name and the parameter. llvm-svn: 313653
Diffstat (limited to 'clang/lib/CodeGen/CodeGenAction.cpp')
-rw-r--r--clang/lib/CodeGen/CodeGenAction.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/clang/lib/CodeGen/CodeGenAction.cpp b/clang/lib/CodeGen/CodeGenAction.cpp
index a29e8de317f..3873ef4eb58 100644
--- a/clang/lib/CodeGen/CodeGenAction.cpp
+++ b/clang/lib/CodeGen/CodeGenAction.cpp
@@ -53,19 +53,20 @@ namespace clang {
: CodeGenOpts(CGOpts), BackendCon(BCon) {}
bool handleDiagnostics(const DiagnosticInfo &DI) override;
- bool isAnalysisRemarkEnable(const std::string &PassName) {
+
+ bool isAnalysisRemarkEnabled(StringRef PassName) const override {
return (CodeGenOpts.OptimizationRemarkAnalysisPattern &&
CodeGenOpts.OptimizationRemarkAnalysisPattern->match(PassName));
}
- bool isMissedOptRemarkEnable(const std::string &PassName) {
+ bool isMissedOptRemarkEnabled(StringRef PassName) const override {
return (CodeGenOpts.OptimizationRemarkMissedPattern &&
CodeGenOpts.OptimizationRemarkMissedPattern->match(PassName));
}
- bool isPassedOptRemarkEnable(const std::string &PassName) {
+ bool isPassedOptRemarkEnabled(StringRef PassName) const override {
return (CodeGenOpts.OptimizationRemarkPattern &&
CodeGenOpts.OptimizationRemarkPattern->match(PassName));
}
-
+
private:
const CodeGenOptions &CodeGenOpts;
BackendConsumer *BackendCon;
OpenPOWER on IntegriCloud