[PATCH] D50378: [clang-format] comment reflow: add last line's penalty when ending broken

2018-08-07 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added a subscriber: cfe-commits. This fixes a bug in clang-format where the last line's penalty is not taken into account when its ending is broken. Usually the last line's penalty is handled by addNextStateToQueue, but in cases where the trailing `*/` is put

[PATCH] D50378: [clang-format] comment reflow: add last line's penalty when ending broken

2018-08-07 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC339123: [clang-format] comment reflow: add last line's penalty when ending broken (authored by krasimir, committed by ). Changed prior to commit: https://reviews.llvm.org/D50378?vs=159474&id=159476#toc

[PATCH] D50378: [clang-format] comment reflow: add last line's penalty when ending broken

2018-08-07 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL339123: [clang-format] comment reflow: add last line's penalty when ending broken (authored by krasimir, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llv

[PATCH] D46519: [clang-format] Respect BreakBeforeClosingBrace while calculating length

2018-05-09 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC331857: [clang-format] Respect BreakBeforeClosingBrace while calculating length (authored by krasimir, committed by ). Changed prior to commit: https://reviews.llvm.org/D46519?vs=145677&id=145881#toc R

[PATCH] D46757: [clang-format] Break inside submessages containing a submessage and something else

2018-05-11 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added subscribers: cfe-commits, klimek. TODO Repository: rC Clang https://reviews.llvm.org/D46757 Files: lib/Format/ContinuationIndenter.cpp lib/Format/TokenAnnotator.cpp lib/Format/UnwrappedLineFormatter.cpp unittests/Format/FormatTestProto.cpp

[PATCH] D46824: [clang-format] Continue after non-scope-closers in getLengthToMatchingParen

2018-05-14 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added subscribers: cfe-commits, klimek. This fixes a regression introduced by `r331857` where we stop the search for the End token as soon as we hit a non-scope-closer, which prematurely stops before semicolons for example, which should otherwise be consider

[PATCH] D46824: [clang-format] Continue after non-scope-closers in getLengthToMatchingParen

2018-05-14 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rC332225: [clang-format] Continue after non-scope-closers in getLengthToMatchingParen (authored by krasimir, committed by ).

[PATCH] D47191: [clang-format] Fix crash in getLengthToMatchingParen

2018-05-22 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added subscribers: cfe-commits, klimek. Found by oss-fuzz: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=8212 Repository: rC Clang https://reviews.llvm.org/D47191 Files: lib/Format/ContinuationIndenter.cpp Index: lib/Format/ContinuationInden

[PATCH] D47191: [clang-format] Fix crash in getLengthToMatchingParen

2018-05-22 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rL332961: [clang-format] Fix crash in getLengthToMatchingParen (authored by krasimir, committed by ). Herald added a subscri

[PATCH] D47191: [clang-format] Fix crash in getLengthToMatchingParen

2018-05-22 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added a comment. Added a test in https://reviews.llvm.org/rL332974. Didn't add a test case and didn't wait for review. Sorry about that! Repository: rL LLVM https://reviews.llvm.org/D47191 ___ cfe-commits mailing list cfe-commits@lists.

[PATCH] D47195: [clang-format] Fix ObjC message arguments handling

2018-05-22 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: unittests/Format/FormatTestObjC.cpp:815 + + // No line break before closing receiver's scope. + verifyFormat("[[obj a:42] a:42\n" What's the receiver's scope in this comment referring to? Also, how would the old test

[PATCH] D47195: [clang-format] Fix ObjC message arguments handling

2018-05-22 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: unittests/Format/FormatTestObjC.cpp:815 + + // No line break before closing receiver's scope. + verifyFormat("[[obj a:42] a:42\n" jolesiak wrote: > krasimir wrote: > > What's the receiver's scope in this comment refer

[PATCH] D47195: [clang-format] Fix putting ObjC message arguments in one line for multiline receiver

2018-05-22 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: unittests/Format/FormatTestObjC.cpp:815 + + // No line break before closing receiver's scope. + verifyFormat("[[obj a:42] a:42\n" jolesiak wrote: > krasimir wrote: > > jolesiak wrote: > > > krasimir wrote: > > > > Wha

[PATCH] D47257: [clang-format] Break template declarations followed by comments

2018-05-23 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added subscribers: cfe-commits, klimek. This patch fixes two bugs in clang-format where the template wrapper doesn't skip over comments causing a long template declaration to not be split into multiple lines. These were latent and exposed by r332436. Repo

[PATCH] D47257: [clang-format] Break template declarations followed by comments

2018-05-23 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL333085: [clang-format] Break template declarations followed by comments (authored by krasimir, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D472

[PATCH] D38243: [clang-format] Add ext/ to google include categories

2017-09-25 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added a subscriber: klimek. This adds an ext/ header include category for google style. https://reviews.llvm.org/D38243 Files: lib/Format/Format.cpp Index: lib/Format/Format.cpp === --- li

[PATCH] D37695: [clang-format] Break non-trailing comments, try 2

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

[PATCH] D38243: [clang-format] Add ext/ to google include categories

2017-09-26 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL314211: [clang-format] Add ext/ to google include categories (authored by krasimir). Repository: rL LLVM https://reviews.llvm.org/D38243 Files: cfe/trunk/lib/Format/Format.cpp Index: cfe/trunk/lib

[PATCH] D37695: [clang-format] Break non-trailing comments, try 2

2017-09-26 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 116742. krasimir added a comment. - Change bool from Paren to Line and generalize it https://reviews.llvm.org/D37695 Files: lib/Format/BreakableToken.cpp lib/Format/BreakableToken.h lib/Format/ContinuationIndenter.cpp lib/Format/ContinuationIndente

[PATCH] D37904: [clang-format] Fix FixNamespaceComments when BraceWrapping AfterNamespace is true.

2017-09-26 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir accepted this revision. krasimir added a comment. This revision is now accepted and ready to land. Looks good! I must have gotten confused with my test suggestion. Do you have commit access, or should I commit this for you? https://reviews.llvm.org/D37904 ___

[PATCH] D37973: [clang-format] Fix regression about short functions after #else

2017-10-02 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL314683: [clang-format] Fix regression about short functions after #else (authored by krasimir). Repository: rL LLVM https://reviews.llvm.org/D37973 Files: cfe/trunk/lib/Format/UnwrappedLineFormatter

[PATCH] D37695: [clang-format] Break non-trailing comments, try 2

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

[PATCH] D37695: [clang-format] Break non-trailing comments, try 2

2017-10-16 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL315893: [clang-format] Break non-trailing comments, try 2 (authored by krasimir). Repository: rL LLVM https://reviews.llvm.org/D37695 Files: cfe/trunk/lib/Format/BreakableToken.cpp cfe/trunk/lib/F

[PATCH] D38731: [clangd] Allow to pass code completion opts to ClangdServer.

2017-10-16 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir accepted this revision. krasimir added a comment. This revision is now accepted and ready to land. Great! I like the unit testing approach a lot! https://reviews.llvm.org/D38731 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http:/

[PATCH] D39024: [clang-format] Sort whole block of using declarations while partially formatting

2017-10-17 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added a subscriber: klimek. This patch enables sorting the full block of using declarations when some line is affected. https://reviews.llvm.org/D39024 Files: lib/Format/UsingDeclarationsSorter.cpp unittests/Format/UsingDeclarationsSorterTest.cpp Inde

[PATCH] D35541: [CMake] Use #cmakedefine01 for CLANG_ENABLE_(ARCMT|OBJC_REWRITER|STATIC_ANALYZER)

2017-10-17 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added a comment. How is this even reviewed? Repository: rL LLVM https://reviews.llvm.org/D35541 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D39024: [clang-format] Sort whole block of using declarations while partially formatting

2017-10-18 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 119518. krasimir added a comment. - Address review comments https://reviews.llvm.org/D39024 Files: lib/Format/UsingDeclarationsSorter.cpp unittests/Format/UsingDeclarationsSorterTest.cpp Index: unittests/Format/UsingDeclarationsSorterTest.cpp ===

[PATCH] D39024: [clang-format] Sort whole block of using declarations while partially formatting

2017-10-18 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL316130: [clang-format] Sort whole block of using declarations while partially formatting (authored by krasimir). Repository: rL LLVM https://reviews.llvm.org/D39024 Files: cfe/trunk/lib/Format/Using

[PATCH] D48098: clang-format-diff: Make it work with python3 too

2018-07-25 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added a comment. MarcoFalke: do you need someone to submit this for you? https://reviews.llvm.org/D48098 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D48827: [clang-format ]Extend IncludeCategories regex documentation

2018-07-25 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL337899: [clang-format ]Extend IncludeCategories regex documentation (authored by krasimir, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/D488

[PATCH] D49797: [clang-format] Indent after breaking Javadoc annotated line

2018-07-25 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added subscribers: cfe-commits, acoomans. This patch makes clang-format indent the subsequent lines created by breaking a long javadoc annotated line. Repository: rC Clang https://reviews.llvm.org/D49797 Files: lib/Format/BreakableToken.cpp lib/Form

[PATCH] D49797: [clang-format] Indent after breaking Javadoc annotated line

2018-07-26 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 157452. krasimir added a comment. - Update tests Repository: rC Clang https://reviews.llvm.org/D49797 Files: lib/Format/BreakableToken.cpp lib/Format/BreakableToken.h lib/Format/ContinuationIndenter.cpp unittests/Format/FormatTestComments.cpp

[PATCH] D49797: [clang-format] Indent after breaking Javadoc annotated line

2018-07-27 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 157681. krasimir marked 3 inline comments as done. krasimir added a comment. - Address review comments Repository: rC Clang https://reviews.llvm.org/D49797 Files: lib/Format/BreakableToken.cpp lib/Format/BreakableToken.h lib/Format/ContinuationInd

[PATCH] D49797: [clang-format] Indent after breaking Javadoc annotated line

2018-07-27 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir marked an inline comment as done. krasimir added inline comments. Comment at: lib/Format/BreakableToken.cpp:526 + 0, Content[LineIndex].find_first_of(Blanks)); + if (FirstWord == "@param") +return Style.ContinuationIndentWidth; mprobst wrote: >

[PATCH] D49797: [clang-format] Indent after breaking Javadoc annotated line

2018-07-27 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: lib/Format/Format.cpp:814 +// by qualified identifiers. +GoogleStyle.CommentPragmas = "(taze:|^/[ \t]*<|@see|@exports|@module|@mods)"; GoogleStyle.MaxEmptyLinesToKeep = 3; mprobst wrote: > `@exports` isn't

[PATCH] D49797: [clang-format] Indent after breaking Javadoc annotated line

2018-07-30 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 157925. krasimir added a comment. - Address comments Repository: rC Clang https://reviews.llvm.org/D49797 Files: lib/Format/BreakableToken.cpp lib/Format/BreakableToken.h lib/Format/ContinuationIndenter.cpp lib/Format/Format.cpp unittests/Form

[PATCH] D49797: [clang-format] Indent after breaking Javadoc annotated line

2018-07-30 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL338232: [clang-format] Indent after breaking Javadoc annotated line (authored by krasimir, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D49797

[PATCH] D50132: [clang-format] Add some text proto functions to Google style

2018-08-01 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. krasimir added a reviewer: djasper. Herald added subscribers: cfe-commits, acoomans. Adds 2 functions taking a text proto argument. Repository: rC Clang https://reviews.llvm.org/D50132 Files: lib/Format/Format.cpp Index: lib/Format/Format.cpp =

[PATCH] D50138: [clang-format] Add @private to the list of jsdoc annotations

2018-08-01 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. krasimir added a reviewer: mprobst. Herald added subscribers: cfe-commits, acoomans. Repository: rC Clang https://reviews.llvm.org/D50138 Files: lib/Format/BreakableToken.cpp Index: lib/Format/BreakableToken.cpp ==

[PATCH] D50078: clang-format: support aligned nested conditionals formatting

2018-08-01 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added a comment. Could you clarify how each piece is supposed to be aligned in these examples? This is what makes me happy: // column limit V int a = condition1 ? result1 : conditio2 ? result2 : loocondition ? result2 : dition

[PATCH] D50138: [clang-format] Add @private to the list of jsdoc annotations

2018-08-01 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL338519: [clang-format] Add @private to the list of jsdoc annotations (authored by krasimir, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D50138

[PATCH] D50132: [clang-format] Add some text proto functions to Google style

2018-08-01 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL338524: [clang-format] Add some text proto functions to Google style (authored by krasimir, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D50132

[PATCH] D50177: clang-format: fix a crash in comment wraps.

2018-08-02 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir accepted this revision. krasimir added a comment. This revision is now accepted and ready to land. Great! Thank you! Repository: rC Clang https://reviews.llvm.org/D50177 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://list

[PATCH] D50230: clang-format: [JS] don't break comments before any '{'

2018-08-03 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir accepted this revision. krasimir added a comment. This revision is now accepted and ready to land. Great! Thanks! Repository: rC Clang https://reviews.llvm.org/D50230 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.l

[PATCH] D48098: clang-format-diff: Make it work with python3 too

2018-08-03 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL338839: clang-format-diff: Make it work with python3 too (authored by krasimir, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/D48098?vs=15286

[PATCH] D42727: [clang-format] Adds space around angle brackets in text protos

2018-02-06 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 132964. krasimir marked an inline comment as done. krasimir added a comment. - Address review comments Repository: rC Clang https://reviews.llvm.org/D42727 Files: lib/Format/ContinuationIndenter.cpp lib/Format/FormatToken.h lib/Format/TokenAnnotat

[PATCH] D42727: [clang-format] Adds space around angle brackets in text protos

2018-02-06 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL324337: [clang-format] Adds space around angle brackets in text protos (authored by krasimir, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D4272

[PATCH] D42901: Test commit - fixing a comment.

2018-02-06 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir accepted this revision. krasimir added a comment. This revision is now accepted and ready to land. Try committing it now! Repository: rC Clang https://reviews.llvm.org/D42901 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http:/

[PATCH] D42957: [clang-format] Do not break before long string literals in protos

2018-02-06 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added subscribers: cfe-commits, klimek. This patch is a follow-up to r323319 (which disables string literal breaking for text protos) and it disables breaking before long string literals. For example this: key: "long string literal" used to get broke

[PATCH] D42957: [clang-format] Do not break before long string literals in protos

2018-02-06 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 132978. krasimir added a comment. - Update comment Repository: rC Clang https://reviews.llvm.org/D42957 Files: lib/Format/ContinuationIndenter.cpp lib/Format/Format.cpp lib/Format/TokenAnnotator.cpp unittests/Format/FormatTestProto.cpp unittes

[PATCH] D42650: [clang-format] New format param ObjCBinPackProtocolList

2018-02-06 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added a comment. I don't understand why do we introduce an enum option if we are keeping the default behavior for Google style. IMO we should have a single behavior for any style and enforce it. Repository: rC Clang https://reviews.llvm.org/D42650 ___

[PATCH] D42787: clang-format: do not add extra indent when wrapping last parameter

2018-02-07 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added a comment. We could adapt the single-argument version instead, turning: foo(bb + c); into: foo(bb + c); Repository: rC Clang https://reviews.llvm.org/D42787 ___

[PATCH] D42957: [clang-format] Do not break before long string literals in protos

2018-02-08 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL324591: [clang-format] Do not break before long string literals in protos (authored by krasimir, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D4

[PATCH] D43121: clang-format: keep ObjC colon alignment with short object name

2018-02-09 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: unittests/Format/FormatTestObjC.cpp:700 + "withObjectOnMainThread:nil\n" + " waitUntilDone:false];"); + } Could you add an instance where the first one is the longest

[PATCH] D43180: [clang-format] Support text proto extensions

2018-02-12 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added subscribers: cfe-commits, klimek. This adds support for text proto extensions, like: msg { [type.type/ext] { key: value } } Repository: rC Clang https://reviews.llvm.org/D43180 Files: lib/Format/ContinuationIndenter.cpp lib/

[PATCH] D43194: [clang-format] Fix comment indentation in text protos

2018-02-12 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added subscribers: cfe-commits, klimek. This patch fixes a bug where the comment indent of comments in text protos gets messed up because by default paren states get created with AlignColons = true (which makes snese for ObjC). Repository: rC Clang htt

[PATCH] D43194: [clang-format] Fix comment indentation in text protos

2018-02-12 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rC324896: [clang-format] Fix comment indentation in text protos (authored by krasimir, committed by ). Changed prior to com

[PATCH] D43194: [clang-format] Fix comment indentation in text protos

2018-02-12 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rL324896: [clang-format] Fix comment indentation in text protos (authored by krasimir, committed by ). Herald added a subscr

[PATCH] D43180: [clang-format] Support text proto extensions

2018-02-12 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 133872. krasimir added a comment. - Add tests with long [...] Repository: rC Clang https://reviews.llvm.org/D43180 Files: lib/Format/ContinuationIndenter.cpp lib/Format/FormatToken.h lib/Format/TokenAnnotator.cpp unittests/Format/FormatTestProto

[PATCH] D43180: [clang-format] Support text proto extensions

2018-02-12 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir marked an inline comment as done. krasimir added inline comments. Comment at: unittests/Format/FormatTestTextProto.cpp:317 + +TEST_F(FormatTestTextProto, FormatsExtensions) { + verifyFormat("[type] { key: value }"); djasper wrote: > It might be useful t

[PATCH] D43180: [clang-format] Support text proto extensions

2018-02-13 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC324995: [clang-format] Support text proto extensions (authored by krasimir, committed by ). Changed prior to commit: https://reviews.llvm.org/D43180?vs=133872&id=134013#toc Repository: rC Clang http

[PATCH] D43231: [clang-format] Refactor ObjC tests

2018-02-13 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added a comment. I don't believe this is needed: test fails before would fail at the line where test instance is checked, and after they will fail at the checkLanguage function. Repository: rC Clang https://reviews.llvm.org/D43231 ___

[PATCH] D43294: [clang-format] Recognize percents as format specifiers in protos

2018-02-14 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. krasimir added a reviewer: djasper. Herald added subscribers: cfe-commits, klimek. Frequently, a percent in protos denotes a formatting specifier for string replacement. Thus it is desirable to keep the percent together with what follows after it. Repository: r

[PATCH] D43298: [clang-format] Support repeated field lists in protos

2018-02-14 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added subscribers: cfe-commits, klimek. This patch adds support for list initialization of proto repeated fields: keys: [1, 2, 3] Repository: rC Clang https://reviews.llvm.org/D43298 Files: lib/Format/TokenAnnotator.cpp unittests/Format/FormatTes

[PATCH] D43294: [clang-format] Recognize percents as format specifiers in protos

2018-02-14 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC325159: [clang-format] Recognize percents as format specifiers in protos (authored by krasimir, committed by ). Changed prior to commit: https://reviews.llvm.org/D43294?vs=134232&id=134286#toc Reposito

[PATCH] D43312: [clang-format] fix handling of consecutive unary operators

2018-02-15 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: lib/Format/TokenAnnotator.cpp:1497 +!(PrevToken->is(tok::exclaim) && + Style.Language == FormatStyle::LK_JavaScript)) // There aren't any trailing unary operators except for TypeScript's I think

[PATCH] D43298: [clang-format] Support repeated field lists in protos

2018-02-15 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 134427. krasimir added a comment. - Pull out check in lambda - Address review comments Repository: rC Clang https://reviews.llvm.org/D43298 Files: lib/Format/TokenAnnotator.cpp unittests/Format/FormatTestProto.cpp unittests/Format/FormatTestTextPr

[PATCH] D43298: [clang-format] Support repeated field lists in protos

2018-02-15 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL325252: [clang-format] Support repeated field lists in protos (authored by krasimir, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D43298 Files:

[PATCH] D43312: [clang-format] fix handling of consecutive unary operators

2018-02-16 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir accepted this revision. krasimir added a comment. This revision is now accepted and ready to land. Thank you! Do you have commit access or should I commit this for you? Repository: rC Clang https://reviews.llvm.org/D43312 ___ cfe-commits

[PATCH] D43465: [clang-format] Fixup a case of text proto message attributes

2018-02-19 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added subscribers: cfe-commits, klimek. This patch fixes a case where a proto message attribute is wrongly identified as an text proto extension. Repository: rC Clang https://reviews.llvm.org/D43465 Files: lib/Format/TokenAnnotator.cpp unittests/Fo

[PATCH] D43465: [clang-format] Fixup a case of text proto message attributes

2018-02-19 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rL325509: [clang-format] Fixup a case of text proto message attributes (authored by krasimir, committed by ). Herald added a

[PATCH] D43465: [clang-format] Fixup a case of text proto message attributes

2018-02-19 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rC325509: [clang-format] Fixup a case of text proto message attributes (authored by krasimir, committed by ). Changed prior

[PATCH] D43469: [clang-format] Fix text proto extension scope opening detection

2018-02-19 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added subscribers: cfe-commits, klimek. This fixes the detection of scope openers in text proto extensions; previously they were not detected correctly leading to instances like: msg { [aa.bb ] { key: value } } Repository: rC Clang https:/

[PATCH] D43469: [clang-format] Fix text proto extension scope opening detection

2018-02-19 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rC325513: [clang-format] Fix text proto extension scope opening detection (authored by krasimir, committed by ). Changed pr

[PATCH] D43469: [clang-format] Fix text proto extension scope opening detection

2018-02-19 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rL325513: [clang-format] Fix text proto extension scope opening detection (authored by krasimir, committed by ). Herald adde

[PATCH] D33416: [clangd] Allow to use vfs::FileSystem for file accesses.

2017-05-24 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: unittests/clangd/ClangdTests.cpp:298 + const auto SourceContents = + R"cpp( +#include "foo.h" Move this to the previous line. Comment at: unittests/clangd/ClangdTests.cpp:336 + const auto Sourc

[PATCH] D33589: clang-format: consider not splitting tokens in optimization

2017-06-01 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added a comment. I think that what you're trying to solve is not practically that important, is unlikely to improve the handling of comments, and will add a lot of complexity. From a usability perspective, I think that people are happy enough when their comments don't exceed the line l

[PATCH] D33982: [clang-format] Fix alignment of preprocessor trailing comments

2017-06-07 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 101734. krasimir added a comment. - Address review comments https://reviews.llvm.org/D33982 Files: lib/Format/WhitespaceManager.cpp unittests/Format/FormatTestComments.cpp Index: unittests/Format/FormatTestComments.cpp ===

[PATCH] D33982: [clang-format] Fix alignment of preprocessor trailing comments

2017-06-07 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL304912: [clang-format] Fix alignment of preprocessor trailing comments (authored by krasimir). Changed prior to commit: https://reviews.llvm.org/D33982?vs=101734&id=101736#toc Repository: rL LLVM ht

[PATCH] D34033: [clangd] Add parameter and return type information to completion results

2017-06-08 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 101919. krasimir added a comment. - Remove optional chunks. They might contain control characters https://reviews.llvm.org/D34033 Files: clangd/ClangdUnit.cpp test/clangd/completion.test Index: test/clangd/completion.test

[PATCH] D34033: [clangd] Add parameter and return type information to completion results

2017-06-08 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir marked an inline comment as done. krasimir added inline comments. Comment at: clangd/ClangdUnit.cpp:153 Item.kind = getKind(Result.CursorKind); +Item.insertText = CCS->getTypedText(); if (CCS->getBriefComment()) ilya-biryukov wr

[PATCH] D34033: [clangd] Add parameter and return type information to completion results

2017-06-08 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 101921. krasimir marked an inline comment as done. krasimir added a comment. - Add sortText and filterText https://reviews.llvm.org/D34033 Files: clangd/ClangdUnit.cpp test/clangd/completion.test Index: test/clangd/completion.test ===

[PATCH] D34033: [clangd] Add parameter and return type information to completion results

2017-06-08 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL304980: [clangd] Add parameter and return type information to completion results (authored by krasimir). Changed prior to commit: https://reviews.llvm.org/D34033?vs=101921&id=101925#toc Repository: r

[PATCH] D33823: [clang-format] Support sorting using declarations

2017-06-12 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added a comment. @klimek: ping https://reviews.llvm.org/D33823 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D34107: [clangd] Allow to override contents of the file during completion.

2017-06-12 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir accepted this revision. krasimir added inline comments. This revision is now accepted and ready to land. Comment at: unittests/clangd/ClangdTests.cpp:432 + // size the same. + // We complete on the 3rd line(2nd in zero-based numbering), because raw + // string literal

[PATCH] D34148: [clangd] Store references instead of unique_ptrs in ClangdServer.

2017-06-13 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: clangd/ClangdLSPServer.h:75 + LSPDiagnosticsConsumer DiagConsumer; + RealFileSystemProvider FSProvider; + This approach is still inflexible. I'd make ClangdLSPServer : public DiagnosticsConsumer and pass references t

[PATCH] D34148: [clangd] Store references instead of unique_ptrs in ClangdServer.

2017-06-13 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir accepted this revision. krasimir added a comment. This revision is now accepted and ready to land. But, of course, that can be done in a separate commit. https://reviews.llvm.org/D34148 ___ cfe-commits mailing list cfe-commits@lists.llvm.or

[PATCH] D34137: [clangd] Add priority to completion item sort text

2017-06-14 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 102522. krasimir added a comment. - Address review comments https://reviews.llvm.org/D34137 Files: clangd/ClangdUnit.cpp test/clangd/authority-less-uri.test test/clangd/completion.test Index: test/clangd/completion.test =

[PATCH] D32480: clang-format: Add CompactNamespaces option

2017-06-14 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added a comment. Looks good, except for the tests that actually add or fix namespace end comments should be moved to NamespaceEndCommentsFixerTest.cpp. https://reviews.llvm.org/D32480 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D32480: clang-format: Add CompactNamespaces option

2017-06-14 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: unittests/Format/FormatTest.cpp:1394 + "int j;\n" + "}\n" + "}", Re-indent this line. https://reviews.llvm.org/D32480 ___

[PATCH] D34201: [clangd] Move dependencies of ClangdLSPServer out of its implementation

2017-06-14 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir abandoned this revision. krasimir added a comment. On a second thought, meh :D https://reviews.llvm.org/D34201 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D34137: [clangd] Add priority to completion item sort text

2017-06-15 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL305454: [clangd] Add priority to completion item sort text (authored by krasimir). Changed prior to commit: https://reviews.llvm.org/D34137?vs=102522&id=102646#toc Repository: rL LLVM https://review

[PATCH] D33823: [clang-format] Support sorting using declarations

2017-06-19 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 103031. krasimir marked 3 inline comments as done. krasimir added a comment. - Address review comments https://reviews.llvm.org/D33823 Files: include/clang/Format/Format.h lib/Format/CMakeLists.txt lib/Format/Format.cpp lib/Format/UsingDeclarations

[PATCH] D33823: [clang-format] Support sorting using declarations

2017-06-19 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 103032. krasimir added a comment. - Update test case https://reviews.llvm.org/D33823 Files: include/clang/Format/Format.h lib/Format/CMakeLists.txt lib/Format/Format.cpp lib/Format/UsingDeclarationsSorter.cpp lib/Format/UsingDeclarationsSorter.h

[PATCH] D33823: [clang-format] Support sorting using declarations

2017-06-19 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: lib/Format/UsingDeclarationsSorter.cpp:66 + } + return HasIdentifier && Tok && Tok->isOneOf(tok::semi, tok::comma); +} Typz wrote: > could also be followed by an assignment, in case of type alias: > > using foo = b

[PATCH] D34351: Simplify TT_SelectorName assignment logic

2017-06-19 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added a subscriber: klimek. While trying to understand TT_SelectorName, I found 2 redundant checks. Removing them doesn't cause any tests to fail. https://reviews.llvm.org/D34351 Files: lib/Format/TokenAnnotator.cpp Index: lib/Format/TokenAnnotator.cpp

[PATCH] D34441: [clang-format] Support text proto messages

2017-06-21 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 103352. krasimir added a comment. - Remove newline https://reviews.llvm.org/D34441 Files: include/clang/Format/Format.h lib/Format/ContinuationIndenter.cpp lib/Format/Format.cpp lib/Format/TokenAnnotator.cpp lib/Format/UnwrappedLineParser.cpp l

[PATCH] D34441: [clang-format] Support text proto messages

2017-06-21 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added a comment. Tests for `<>`-style message fields are missing because I discovered that they don't really work in a multiline setting in proto options anyways. I'll address this problem separately. https://reviews.llvm.org/D34441 ___ c

[PATCH] D33823: [clang-format] Support sorting using declarations

2017-06-21 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL305901: [clang-format] Support sorting using declarations (authored by krasimir). Changed prior to commit: https://reviews.llvm.org/D33823?vs=103032&id=103359#toc Repository: rL LLVM https://reviews

[PATCH] D34457: [clang-format] Update style documentation, NFC

2017-06-23 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL306089: [clang-format] Update style documentation, NFC (authored by krasimir). Changed prior to commit: https://reviews.llvm.org/D34457?vs=103399&id=103698#toc Repository: rL LLVM https://reviews.ll

  1   2   3   4   5   6   7   8   9   10   >