forked from OSchip/llvm-project
4fc55a76b8
Summary: The added test case was currently crashing with an assertion: ``` krasimir@krasimir> cat test.cc ~ // How to run: // bbbbb run \ // rrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr \ // <log_file> -- --output_directory="<output_directory>" krasimir@krasimir> ~/work/llvm-build/bin/clang-format test.cc ~ clang-format: /usr/local/google/home/krasimir/work/llvm/tools/clang/lib/Format/WhitespaceManager.cpp:117: void clang::format::WhitespaceManager::calculateLineBreakInformation(): Assertion `PreviousOriginalWhitespaceEndOffset <= OriginalWhitespaceStartOffset' failed. ``` The root cause was that BreakableToken was not considering the case of a reflow between an unescaped newline in a line comment. Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D48089 llvm-svn: 334527 |
||
---|---|---|
.. | ||
AffectedRangeManager.cpp | ||
AffectedRangeManager.h | ||
BreakableToken.cpp | ||
BreakableToken.h | ||
CMakeLists.txt | ||
ContinuationIndenter.cpp | ||
ContinuationIndenter.h | ||
Encoding.h | ||
Format.cpp | ||
FormatInternal.h | ||
FormatToken.cpp | ||
FormatToken.h | ||
FormatTokenLexer.cpp | ||
FormatTokenLexer.h | ||
NamespaceEndCommentsFixer.cpp | ||
NamespaceEndCommentsFixer.h | ||
SortJavaScriptImports.cpp | ||
SortJavaScriptImports.h | ||
TokenAnalyzer.cpp | ||
TokenAnalyzer.h | ||
TokenAnnotator.cpp | ||
TokenAnnotator.h | ||
UnwrappedLineFormatter.cpp | ||
UnwrappedLineFormatter.h | ||
UnwrappedLineParser.cpp | ||
UnwrappedLineParser.h | ||
UsingDeclarationsSorter.cpp | ||
UsingDeclarationsSorter.h | ||
WhitespaceManager.cpp | ||
WhitespaceManager.h |