summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Support/SourceMgr.cpp
diff options
context:
space:
mode:
authorAdam Nemet <anemet@apple.com>2017-10-12 23:56:02 +0000
committerAdam Nemet <anemet@apple.com>2017-10-12 23:56:02 +0000
commit01104aee1a3e74e7ecddcfed9f1edfb4e2e99c25 (patch)
tree314994ad4fb8889ecf1f80d9f46ba26c5230252a /llvm/lib/Support/SourceMgr.cpp
parent0e8211ea57fb40fad12c583c05fd95734df906aa (diff)
downloadbcm5719-llvm-01104aee1a3e74e7ecddcfed9f1edfb4e2e99c25.tar.gz
bcm5719-llvm-01104aee1a3e74e7ecddcfed9f1edfb4e2e99c25.zip
Add DK_Remark to SMDiagnostic
Swift uses SMDiagnostic for diagnostic messages. For https://github.com/apple/swift/pull/12294, we need remark support. I picked the color that clang uses to display them. Differential Revision: https://reviews.llvm.org/D38865 llvm-svn: 315642
Diffstat (limited to 'llvm/lib/Support/SourceMgr.cpp')
-rw-r--r--llvm/lib/Support/SourceMgr.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/Support/SourceMgr.cpp b/llvm/lib/Support/SourceMgr.cpp
index b0609d4fe04..a8f6208a558 100644
--- a/llvm/lib/Support/SourceMgr.cpp
+++ b/llvm/lib/Support/SourceMgr.cpp
@@ -384,6 +384,11 @@ void SMDiagnostic::print(const char *ProgName, raw_ostream &S, bool ShowColors,
S.changeColor(raw_ostream::BLACK, true);
S << "note: ";
break;
+ case SourceMgr::DK_Remark:
+ if (ShowColors)
+ S.changeColor(raw_ostream::BLUE, true);
+ S << "remark: ";
+ break;
}
if (ShowColors) {
OpenPOWER on IntegriCloud