diff options
author | Douglas Gregor <dgregor@apple.com> | 2009-03-10 20:44:00 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2009-03-10 20:44:00 +0000 |
commit | df667e71b1daadeacb230cf94fc717843f1a138a (patch) | |
tree | 72ebde19e19176d2cc776ce1dab15dc5c6e0d5c3 /include/clang/Frontend | |
parent | 27b152fa7443f4e24630b997c07def6b0c23925a (diff) |
Extend the notion of active template instantiations to include the
context of a template-id for which we need to instantiate default
template arguments.
In the TextDiagnosticPrinter, don't suppress the caret diagnostic if
we are producing a non-note diagnostic that follows a note diagnostic
with the same location, because notes are (conceptually) a part of the
warning or error that comes before them.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66572 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Frontend')
-rw-r--r-- | include/clang/Frontend/TextDiagnosticPrinter.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/include/clang/Frontend/TextDiagnosticPrinter.h b/include/clang/Frontend/TextDiagnosticPrinter.h index c9fbae6ebb..eeff279513 100644 --- a/include/clang/Frontend/TextDiagnosticPrinter.h +++ b/include/clang/Frontend/TextDiagnosticPrinter.h @@ -28,6 +28,7 @@ class SourceManager; class TextDiagnosticPrinter : public DiagnosticClient { SourceLocation LastWarningLoc; FullSourceLoc LastLoc; + bool LastCaretDiagnosticWasNote; llvm::raw_ostream &OS; bool ShowColumn; bool CaretDiagnostics; @@ -35,8 +36,8 @@ class TextDiagnosticPrinter : public DiagnosticClient { public: TextDiagnosticPrinter(llvm::raw_ostream &os, bool showColumn = true, bool caretDiagnistics = true, bool showLocation = true) - : OS(os), ShowColumn(showColumn), CaretDiagnostics(caretDiagnistics), - ShowLocation(showLocation) {} + : LastCaretDiagnosticWasNote(false), OS(os), ShowColumn(showColumn), + CaretDiagnostics(caretDiagnistics), ShowLocation(showLocation) {} void PrintIncludeStack(SourceLocation Loc, const SourceManager &SM); |