[PATCH] D32524: [clang-format] Fix MatchingOpeningBlockLineIndex computation
Francois Ferrand via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue May 16 06:51:49 PDT 2017
Typz updated this revision to Diff 99136.
Typz added a comment.
Reformat and remove unneeded comment
https://reviews.llvm.org/D32524
Files:
lib/Format/UnwrappedLineParser.cpp
Index: lib/Format/UnwrappedLineParser.cpp
===================================================================
--- lib/Format/UnwrappedLineParser.cpp
+++ lib/Format/UnwrappedLineParser.cpp
@@ -428,8 +428,9 @@
parseParens();
addUnwrappedLine();
- size_t OpeningLineIndex =
- Lines.empty() ? (UnwrappedLine::kInvalidIndex) : (Lines.size() - 1);
+ size_t OpeningLineIndex = CurrentLines->empty()
+ ? (UnwrappedLine::kInvalidIndex)
+ : (CurrentLines->size() - 1);
ScopedDeclarationState DeclarationState(*Line, DeclarationScopeStack,
MustBeDeclaration);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D32524.99136.patch
Type: text/x-patch
Size: 676 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20170516/8c1ef997/attachment.bin>
More information about the cfe-commits
mailing list