summaryrefslogtreecommitdiffstats
path: root/clang/lib/Frontend/VerifyDiagnosticConsumer.cpp
diff options
context:
space:
mode:
authorTobias Grosser <tobias@grosser.es>2014-05-01 14:06:01 +0000
committerTobias Grosser <tobias@grosser.es>2014-05-01 14:06:01 +0000
commit86a85678f2a793dd2e82025f3af25ba45d6bbec1 (patch)
treec60dd9329203815ddef4aaf0326ad1dacede14b7 /clang/lib/Frontend/VerifyDiagnosticConsumer.cpp
parent10961c0eab6bf294818470708625a5d4e786a015 (diff)
downloadbcm5719-llvm-86a85678f2a793dd2e82025f3af25ba45d6bbec1.tar.gz
bcm5719-llvm-86a85678f2a793dd2e82025f3af25ba45d6bbec1.zip
Support 'remark' in VerifyDiagnosticConsumer
After Diego added support for -Rpass=inliner we have now in-tree remarks which we can use to properly test this feature. llvm-svn: 207765
Diffstat (limited to 'clang/lib/Frontend/VerifyDiagnosticConsumer.cpp')
-rw-r--r--clang/lib/Frontend/VerifyDiagnosticConsumer.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/lib/Frontend/VerifyDiagnosticConsumer.cpp b/clang/lib/Frontend/VerifyDiagnosticConsumer.cpp
index d6d01156557..9df39782abb 100644
--- a/clang/lib/Frontend/VerifyDiagnosticConsumer.cpp
+++ b/clang/lib/Frontend/VerifyDiagnosticConsumer.cpp
@@ -330,6 +330,8 @@ static bool ParseDirective(StringRef S, ExpectedData *ED, SourceManager &SM,
DL = ED ? &ED->Errors : NULL;
else if (PH.Next("warning"))
DL = ED ? &ED->Warnings : NULL;
+ else if (PH.Next("remark"))
+ DL = ED ? &ED->Remarks : NULL;
else if (PH.Next("note"))
DL = ED ? &ED->Notes : NULL;
else if (PH.Next("no-diagnostics")) {
@@ -737,6 +739,10 @@ static unsigned CheckResults(DiagnosticsEngine &Diags, SourceManager &SourceMgr,
NumProblems += CheckLists(Diags, SourceMgr, "warning", ED.Warnings,
Buffer.warn_begin(), Buffer.warn_end());
+ // See if there are remark mismatches.
+ NumProblems += CheckLists(Diags, SourceMgr, "remark", ED.Remarks,
+ Buffer.remark_begin(), Buffer.remark_end());
+
// See if there are note mismatches.
NumProblems += CheckLists(Diags, SourceMgr, "note", ED.Notes,
Buffer.note_begin(), Buffer.note_end());
OpenPOWER on IntegriCloud