aboutsummaryrefslogtreecommitdiff
path: root/lib/Format/UnwrappedLineParser.h
diff options
context:
space:
mode:
authorAlexander Kornienko <alexfh@google.com>2013-01-10 15:05:09 +0000
committerAlexander Kornienko <alexfh@google.com>2013-01-10 15:05:09 +0000
commit3048aeae0654b34dcae561494c1b28872c88a5c8 (patch)
treec1e7d87e4041429ea47308b19cfca5244f7ec83f /lib/Format/UnwrappedLineParser.h
parent2851c16443dcdb9d8bb509d321fb827a560b47bc (diff)
Basic support for diagnostics.
Summary: Uses DiagnosticsEngine to output diagnostics. Reviewers: djasper, klimek Reviewed By: djasper CC: cfe-commits Differential Revision: http://llvm-reviews.chandlerc.com/D278 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@172071 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Format/UnwrappedLineParser.h')
-rw-r--r--lib/Format/UnwrappedLineParser.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/Format/UnwrappedLineParser.h b/lib/Format/UnwrappedLineParser.h
index 017daf587f..837b5391f6 100644
--- a/lib/Format/UnwrappedLineParser.h
+++ b/lib/Format/UnwrappedLineParser.h
@@ -27,6 +27,9 @@
#include <vector>
namespace clang {
+
+class DiagnosticsEngine;
+
namespace format {
/// \brief A wrapper around a \c Token storing information about the
@@ -116,7 +119,8 @@ public:
class UnwrappedLineParser {
public:
- UnwrappedLineParser(const FormatStyle &Style, FormatTokenSource &Tokens,
+ UnwrappedLineParser(clang::DiagnosticsEngine &Diag, const FormatStyle &Style,
+ FormatTokenSource &Tokens,
UnwrappedLineConsumer &Callback);
/// Returns true in case of a structural error.
@@ -161,6 +165,7 @@ private:
FormatToken FormatTok;
bool MustBreakBeforeNextToken;
+ clang::DiagnosticsEngine &Diag;
const FormatStyle &Style;
FormatTokenSource *Tokens;
UnwrappedLineConsumer &Callback;