aboutsummaryrefslogtreecommitdiff
path: root/lib/Format/UnwrappedLineParser.h
diff options
context:
space:
mode:
authorDaniel Jasper <djasper@google.com>2013-01-16 10:41:46 +0000
committerDaniel Jasper <djasper@google.com>2013-01-16 10:41:46 +0000
commit3f8cdbf9932c874b7ca4ee3d850a236d9c729961 (patch)
treed43034baed4deb1cf11575ad7a0197caaee749c6 /lib/Format/UnwrappedLineParser.h
parentcbb6c41f3cec4a940201a8e2e65743c9f26c3673 (diff)
Calculate the total length of a line up to each token up front.
This makes the tedious fitsIntoLimit() method unnecessary and I can replace one hack (constructor initializers) by a slightly better hack. Furthermore, this will enable calculating whether a certain part of a line fits into the limit for future modifications. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@172604 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Format/UnwrappedLineParser.h')
-rw-r--r--lib/Format/UnwrappedLineParser.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/Format/UnwrappedLineParser.h b/lib/Format/UnwrappedLineParser.h
index 21a973d9dd..c261732032 100644
--- a/lib/Format/UnwrappedLineParser.h
+++ b/lib/Format/UnwrappedLineParser.h
@@ -88,6 +88,7 @@ struct UnwrappedLine {
UnwrappedLine() : Level(0), InPPDirective(false) {
}
+ // FIXME: Don't use std::list here.
/// \brief The \c Tokens comprising this \c UnwrappedLine.
std::list<FormatToken> Tokens;