[PATCH] D35485: [clang-format] Fix comment levels between '}' and PPDirective

2017-07-21 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL308725: [clang-format] Fix comment levels between '}' and PPDirective (authored by krasimir). Repository: rL LLVM https://reviews.llvm.org/D35485 Files: cfe/trunk/lib/Format/UnwrappedLineParser.cpp

[PATCH] D35485: [clang-format] Fix comment levels between '}' and PPDirective

2017-07-21 Thread Daniel Jasper via Phabricator via cfe-commits
djasper accepted this revision. djasper added a comment. This revision is now accepted and ready to land. Looks good. https://reviews.llvm.org/D35485 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listi

[PATCH] D35485: [clang-format] Fix comment levels between '}' and PPDirective

2017-07-21 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added a comment. @djasper: ping https://reviews.llvm.org/D35485 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D35485: [clang-format] Fix comment levels between '}' and PPDirective

2017-07-19 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 107314. krasimir added a comment. - Adapt the fix from comment suggestion https://reviews.llvm.org/D35485 Files: lib/Format/UnwrappedLineParser.cpp unittests/Format/FormatTestComments.cpp Index: unittests/Format/FormatTestComments.cpp

[PATCH] D35485: [clang-format] Fix comment levels between '}' and PPDirective

2017-07-19 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: lib/Format/UnwrappedLineParser.cpp:489 - nextToken(); // Munch the closing brace. + nextToken(InitialLevel); // Munch the closing brace. djasper wrote: > krasimir wrote: > > djasper wrote: > > > krasimir wrote: >

[PATCH] D35485: [clang-format] Fix comment levels between '}' and PPDirective

2017-07-19 Thread Daniel Jasper via Phabricator via cfe-commits
djasper added inline comments. Comment at: lib/Format/UnwrappedLineParser.cpp:489 - nextToken(); // Munch the closing brace. + nextToken(InitialLevel); // Munch the closing brace. krasimir wrote: > djasper wrote: > > krasimir wrote: > > > djasper wrote: > >

[PATCH] D35485: [clang-format] Fix comment levels between '}' and PPDirective

2017-07-19 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 107285. krasimir marked 2 inline comments as done. krasimir added a comment. - Manually messed up tests https://reviews.llvm.org/D35485 Files: lib/Format/UnwrappedLineParser.cpp lib/Format/UnwrappedLineParser.h unittests/Format/FormatTestComments.cpp

[PATCH] D35485: [clang-format] Fix comment levels between '}' and PPDirective

2017-07-18 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir marked 2 inline comments as done. krasimir added inline comments. Comment at: lib/Format/UnwrappedLineParser.cpp:489 - nextToken(); // Munch the closing brace. + nextToken(InitialLevel); // Munch the closing brace. djasper wrote: > krasimir wrote:

[PATCH] D35485: [clang-format] Fix comment levels between '}' and PPDirective

2017-07-18 Thread Daniel Jasper via Phabricator via cfe-commits
djasper added inline comments. Comment at: lib/Format/UnwrappedLineParser.cpp:2378 ScopedLineState BlockState(*this, SwitchToPreprocessorLines); + if (InitialLevel) +Line->Level = *InitialLevel; What happens if we always set the Level to 0 her

[PATCH] D35485: [clang-format] Fix comment levels between '}' and PPDirective

2017-07-18 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 107087. krasimir added a comment. - Remove TODO test case https://reviews.llvm.org/D35485 Files: lib/Format/UnwrappedLineParser.cpp lib/Format/UnwrappedLineParser.h unittests/Format/FormatTestComments.cpp Index: unittests/Format/FormatTestComments.c

[PATCH] D35485: [clang-format] Fix comment levels between '}' and PPDirective

2017-07-18 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 107038. krasimir marked 2 inline comments as done. krasimir added a comment. - Fix formatting https://reviews.llvm.org/D35485 Files: lib/Format/UnwrappedLineParser.cpp lib/Format/UnwrappedLineParser.h unittests/Format/FormatTestComments.cpp Index: u

[PATCH] D35485: [clang-format] Fix comment levels between '}' and PPDirective

2017-07-18 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: lib/Format/UnwrappedLineParser.cpp:489 - nextToken(); // Munch the closing brace. + nextToken(InitialLevel); // Munch the closing brace. djasper wrote: > What happens if you instead change the Line->Level = Initia

[PATCH] D35485: [clang-format] Fix comment levels between '}' and PPDirective

2017-07-18 Thread Daniel Jasper via Phabricator via cfe-commits
djasper added inline comments. Comment at: lib/Format/UnwrappedLineParser.cpp:489 - nextToken(); // Munch the closing brace. + nextToken(InitialLevel); // Munch the closing brace. What happens if you instead change the Line->Level = InitialLevel; statement