[PATCH] D75791: [clang-format] Added new option IndentExternBlock

2020-05-17 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. Please clang-format the patch CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75791/new/ https://reviews.llvm.org/D75791 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/ma

[PATCH] D75791: [clang-format] Added new option IndentExternBlock

2020-05-17 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/include/clang/Format/Format.h:1555 + IndentExternBlockStyle IndentExternBlock; + /// A vector of prefixes ordered by the desired groups for Java imports. Something is not quie right here, this text isn't

[PATCH] D80079: [clang-format] [NFC] isCpp() is inconsistently used to mean both C++ and Objective C, add language specific isXXX() functions

2020-05-18 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. - I personally find the current form (Style.Language == LK_XXX) very verbose and difficult to read, especially when its in the middle of a large clause. - Its clear to me that isCpp() is not understood, its name doesn't quite suggest what it does and as such there

[PATCH] D80079: [clang-format] [NFC] isCpp() is inconsistently used to mean both C++ and Objective C, add language specific isXXX() functions

2020-05-18 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay marked 2 inline comments as done. MyDeveloperDay added inline comments. Comment at: clang/lib/Format/TokenAnnotator.cpp:3443 - Style.Language == FormatStyle::LK_TextProto) { + } else if (Style.isCpp() || Style.isProtoBuf() || Style.isTableGen() || +

[PATCH] D80115: [clang-format] [PR45816] Add AlignConsecutiveBitFields

2020-05-18 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay created this revision. MyDeveloperDay added reviewers: krasimir, mitchell-stellar, JakeMerdichAMD, curdeius, owenpan. MyDeveloperDay added projects: clang, clang-format. MyDeveloperDay updated this revision to Diff 264575. MyDeveloperDay added a comment. MyDeveloperDay edited the su

[PATCH] D80115: [clang-format] [PR45816] Add AlignConsecutiveBitFields

2020-05-18 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 264575. MyDeveloperDay added a comment. clang-format CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80115/new/ https://reviews.llvm.org/D80115 Files: clang/docs/ClangFormatStyleOptions.rst clang/docs/ReleaseNotes.rst clang/include/clang

[PATCH] D80115: [clang-format] [PR45816] Add AlignConsecutiveBitFields

2020-05-18 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay planned changes to this revision. MyDeveloperDay marked an inline comment as done. MyDeveloperDay added inline comments. Comment at: clang/lib/Format/WhitespaceManager.cpp:588-590 +return C.Tok->Previous->startsSequence(tok::identifier, tok::colon, +

[PATCH] D80115: [clang-format] [PR45816] Add AlignConsecutiveBitFields

2020-05-18 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. How about we combine the two revisions CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80115/new/ https://reviews.llvm.org/D80115 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/c

[PATCH] D75791: [clang-format] Added new option IndentExternBlock

2020-05-18 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. I've added you to https://reviews.llvm.org/project/view/78/ Comment at: clang/include/clang/Format/Format.h:1555 + IndentExternBlockStyle IndentExternBlock; + /// A vector of prefixes ordered by the desired groups for Java imports. --

[PATCH] D75791: [clang-format] Added new option IndentExternBlock

2020-05-18 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. Sorry forgot to submit the comment issue, seems like you worked that bit out already CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75791/new/ https://reviews.llvm.org/D75791 ___ cfe-commits mailing list cfe-

[PATCH] D75791: [clang-format] Added new option IndentExternBlock

2020-05-18 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. > if thats true how didn't the automated tests catch it? If you are not in the premerge testing group the unit tests won't be run. (which is why I added you) When I run the gtest it fails, I cannot see why.. but one suggestion I have is to drop the whole true/fa

[PATCH] D75791: [clang-format] Added new option IndentExternBlock

2020-05-18 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. ok it crashes because you are not initializing IndentExternBlock in the getLLVMStyle() function LLVMStyle.IndentExternBlock = FormatStyle::IEBS_NoIndent; You cannot leave it uninitialized, now what the correct value is in my view may be an issue CHANGES SINCE

[PATCH] D75791: [clang-format] Added new option IndentExternBlock

2020-05-18 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. I think it needs to be: `LLVMStyle.IndentExternBlock = FormatStyle::IEBS_NoIndent;` I'm wondering if the GNU style also needs `Expanded.IndentExternBlock = FormatStyle::IEBS_Indent;` CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75791/new/ https://revi

[PATCH] D80115: [clang-format] [PR45816] Add AlignConsecutiveBitFields

2020-05-18 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. How about I abandon and we use yours (but would you please consider changing the name to be AlignConsecutiveBitFields ) (capital F) as that was in the orignal request CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80115/new/ https://reviews.llvm.org/D80

[PATCH] D80144: [clang-format] @lefticus just taught the world how to use [[unlikely]] but we forgot to teach clang-format

2020-05-18 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay created this revision. MyDeveloperDay added reviewers: krasimir, mitchell-stellar, JakeMerdichAMD, curdeius, lefticus. MyDeveloperDay added projects: clang, clang-format. https://twitter.com/lefticus/status/1262392152950288384?s=20 Jason Turner's (@lefticus) most recent C++ weekly

[PATCH] D80144: [clang-format] @lefticus just taught the world how to use [[unlikely]] but we forgot to teach clang-format

2020-05-18 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 264717. MyDeveloperDay added a comment. rebase CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80144/new/ https://reviews.llvm.org/D80144 Files: clang/lib/Format/UnwrappedLineParser.cpp clang/unittests/Format/FormatTest.cpp Index: clang/

[PATCH] D80176: [clang-format][PR45816] Add AlignConsecutiveBitFields

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. This revision is now accepted and ready to land. The LGTM (nit: clang-format) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80176/new/ https://reviews.llvm.org/D80176 ___

[PATCH] D75791: [clang-format] Added new option IndentExternBlock

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added subscribers: Abpostelnicu, sylvestre.ledru. MyDeveloperDay added a comment. This is totally fine, now I'm just concerned by the choice of defaults, I really don't know if we want to change the defaults for all the styles, I don't want to break all those people using it One

[PATCH] D80144: [clang-format] @lefticus just taught the world how to use [[unlikely]] but we forgot to teach clang-format

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. In D80144#2042926 , @JakeMerdichAMD wrote: > This is a great improvement in readability. I think this will get in here > before it does for clang proper :D > > Likely/unlikely also seem to be supported on while, do-while,

[PATCH] D79773: [clang-format] Improve clang-formats handling of concepts

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay marked 6 inline comments as done. MyDeveloperDay added a subscriber: STL_MSFT. MyDeveloperDay added inline comments. Comment at: clang/lib/Format/TokenAnnotator.cpp:1566 Current.Type = TT_TrailingReturnArrow; - +} else if (Current.is(tok::arrow) && Curre

[PATCH] D79773: [clang-format] Improve clang-formats handling of concepts

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay planned changes to this revision. MyDeveloperDay marked 4 inline comments as done. MyDeveloperDay added inline comments. Comment at: clang/lib/Format/TokenAnnotator.cpp:3499 return true; if (Right.Previous->ClosesTemplateDeclaration && Right.Previous

[PATCH] D75791: [clang-format] Added new option IndentExternBlock

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. > btw, in .BraceWrapping = {true, false); blocks, AfterExternBlock is the 9th > option, I checked the BraceWrapping enum. This will become clearer I hope when I land D79325: [clang-format] [PR42164] Add Option to Break before While

[PATCH] D75791: [clang-format] Added new option IndentExternBlock

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. All this confusion over the defaults is because we don't have the unit tests to check the default of each style. If we had that we could have a before/after conversation more easily Nit: also please mark comments done once you have addressed them.

[PATCH] D75791: [clang-format] Added new option IndentExternBlock

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. Sorry to "go around the houses" but we'll get there in the end...I think we are close CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75791/new/ https://reviews.llvm.org/D75791 ___ cfe-commits mailing list cfe

[PATCH] D79773: [clang-format] Improve clang-formats handling of concepts

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 264851. MyDeveloperDay added a comment. Move break before concept into correct clause Add `requires requires` test CHANGES SINCE LAST ACTION https://reviews.llvm.org/D79773/new/ https://reviews.llvm.org/D79773 Files: clang/docs/ClangFormatStyleO

[PATCH] D75791: [clang-format] Added new option IndentExternBlock

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. This is what I was thinking about D80214: [clang-format] Set of unit test to begin to validate that we don't change defaults CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75791/new/ https://reviews.llvm.org/D75791 __

[PATCH] D80214: [clang-format] Set of unit test to begin to validate that we don't change defaults

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay created this revision. MyDeveloperDay added reviewers: MarcusJohnson91, krasimir, JakeMerdichAMD. MyDeveloperDay added projects: clang, clang-format. This revision is to complement D75791: [clang-format] Added new option IndentExternBlock so we can

[PATCH] D75791: [clang-format] Added new option IndentExternBlock

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. I think this LGTM now... CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75791/new/ https://reviews.llvm.org/D75791 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D80008: [clang-format] [PR45942] [[nodiscard]] causes && to be miss interpreted as BinaryOperators

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG6189dd06ad48: [clang-format] [PR45942] [[nodiscard]] causes && to be miss interpreted as… (authored by MyDeveloperDay). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.l

[PATCH] D79905: [clang-format] [PR44476] Add space between template and attribute

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG07740dd08b57: [clang-format] [PR44476] Add space between template and attribute (authored by MyDeveloperDay). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D7

[PATCH] D79990: [clang-format] [PR45614] Incorrectly indents [[nodiscard]] attribute funtions after a macro without semicolon

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG575c59cf6a32: [clang-format] [PR45614] Incorrectly indents [[nodiscard]] attribute funtions… (authored by MyDeveloperDay). Changed prior to commit: https://reviews.llvm.org/D79990?vs=264231&id=264942#to

[PATCH] D80144: [clang-format] @lefticus just taught the world how to use [[unlikely]] but we forgot to teach clang-format

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG5d82cb3c3a6a: [clang-format] @lefticus just taught the world how to use [[unlikely]] but we… (authored by MyDeveloperDay). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://review

[PATCH] D75791: [clang-format] Added new option IndentExternBlock

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. If you want me to land this for you, I'd feel more comfortable landing it if: a) We can land D80214: [clang-format] Set of unit test to begin to validate that we don't change defaults first b) The Mozilla team have tested the impa

[PATCH] D80228: [clang-format] [PR33890] Add support for Microsoft C++/CLI non standard for each looping extension

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay created this revision. MyDeveloperDay added reviewers: krasimir, JakeMerdichAMD, mitchell-stellar. MyDeveloperDay added projects: clang, clang-format. https://bugs.llvm.org/show_bug.cgi?id=33890 This revision allow the microsoft `for each( in ...` nonstandard C++ extension whi

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

2020-05-19 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. https://bugs.llvm.org/show_bug.cgi?id=33896 shows an interesting use case (when using UseTab: Always) std::string CLogView::GetItemText(int item) const { return item == 1 ? "one" : item == 2 ? "two" : item == 3 ? "three" : it

[PATCH] D132805: [clang-format] Fix a bug in removing braces for the LLVM style

2022-08-27 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D132805/new/ https://reviews.llvm.org/D132805 ___

[PATCH] D132762: [clang-format] Allow `throw` to be a keyword in front of casts

2022-08-27 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. This revision is now accepted and ready to land. This at least seems to make sense Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D132762/new/ https://reviews.llvm.org/D132762 __

[PATCH] D132762: [clang-format] Allow `throw` to be a keyword in front of casts

2022-08-29 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/unittests/Format/FormatTest.cpp:10961 verifyFormat("return (my_int)aaa;"); + verifyFormat("throw (my_int)aaa;"); verifyFormat("#define x ((int)-1)"); Can we add a test that covers the setting of Space

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-08-29 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/docs/ClangFormatStyleOptions.rst:785 + - Consecutive + - AcrossEmptyLines + - AcrossComments may be AcrossEmptyLines should be a number (to mean the number of empty lines) Comment at: c

[PATCH] D132911: [clang-format] Fix annotating when deleting array of pointers

2022-08-30 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/lib/Format/TokenAnnotator.cpp:2379 +Prev->is(tok::kw_delete)) + return TT_UnaryOperator; + Why unary here, doesn’t that make it a multiply? Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D132911: [clang-format] Fix annotating when deleting array of pointers

2022-08-30 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Format/TokenAnnotator.cpp:2381-2385 if (PrevToken->Tok.isLiteral() || PrevToken->isOneOf(tok::r_paren, tok::r_square,

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-02 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. Is there a technical reason for reusing the struct rather than introducing a new one? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D132131/new/ https://reviews.llvm.org/D132131 _

[PATCH] D132256: [clang-format] Add DefinitionBlockSpacing option

2022-09-02 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/docs/ClangFormatStyleOptions.rst:2429 + This determines the number of empty lines to use when + SeparateDefinitionBlocks == SeparateDefinitionStyle::SDS_Always. + Can you write this not in terms of the cod

[PATCH] D67949: [clang-format] [PR36858] Add missing .hh and .cs extensions from python support utilities

2022-09-02 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. Herald added a project: All. We are also missing json Repository: rL LLVM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67949/new/ https://reviews.llvm.org/D67949 ___ cfe-commits mailing list cfe-commits@lis

[PATCH] D132550: Changes to code ownership in clang and clang-tidy

2022-09-02 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. This revision is now accepted and ready to land. +1 to the rst format CHANGES SINCE LAST ACTION https://reviews.llvm.org/D132550/new/ https://reviews.llvm.org/D132550 ___ cfe-co

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-05 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. I feel this patch leave the documentation in a right state, I won’t be giving it an accept in this form. Please also mark the comments as done once addressed so we know you’ve read and fixed our requests Comment at: clang/docs/ClangFormatStyleO

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-05 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/docs/ClangFormatStyleOptions.rst:794 + +AlignConsecutiveMacros: AcrossEmptyLines + HazardyKnusperkeks wrote: > yusuke-kadowaki wrote: > > MyDeveloperDay wrote: > > > Should this say `AlignedConsecutuveCo

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-05 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. My personal preference is a new struct without Enabled Comment at: clang/lib/Format/Format.cpp:1196 LLVMStyle.AlignConsecutiveMacros = {}; + LLVMStyle.AlignConsecutiveTrailingComments = {}; + LLVMStyle.AlignConsecutiveTrailingComments.Enable

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-05 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/include/clang/Format/Format.h:298 + /// Style of aligning consecutive trailing comments. + /// This option existed as ``AlignTrailingComments`` since version 3.7. + /// yusuke-kadowaki wrote: > MyDevelope

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-05 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/unittests/Format/FormatTestComments.cpp:2930 + Style.ColumnLimit = 15; + EXPECT_EQ("int ab; // line\n" +"int a; // long\n" Why not verifyFormat here too and below? Repository: rG LLVM Gith

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-05 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. In D132131#3771005 , @HazardyKnusperkeks wrote: > In D132131#3770170 , > @MyDeveloperDay wrote: > >> My personal preference is a new struct without Enabled > > We go for a new str

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-06 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/unittests/Format/FormatTestComments.cpp:2930 + Style.ColumnLimit = 15; + EXPECT_EQ("int ab; // line\n" +"int a; // long\n" yusuke-kadowaki wrote: > MyDeveloperDay wrote: > > Why not verifyForm

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-06 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/docs/ClangFormatStyleOptions.rst:865 + + * ``TCAS_DontAlign`` (in configuration: ``DontAlign``) +Don't align trailing comments. Is Don'tAlign the same as Leave that other options support (for options i

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-07 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/docs/ClangFormatStyleOptions.rst:865 + + * ``TCAS_DontAlign`` (in configuration: ``DontAlign``) +Don't align trailing comments. yusuke-kadowaki wrote: > MyDeveloperDay wrote: > > Is Don'tAlign the same

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-08 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. an example of the exact reason why we should not reuse the same struct... https://github.com/llvm/llvm-project/issues/57464 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D132131/new/ https://reviews.llvm.org/D13213

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-08 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. another reason for using a struct, is that we might want to say something like "AlignNamespaceTrainingComments:false" https://github.com/llvm/llvm-project/issues/57504 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D1

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-09 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. struct Style { enum E { Yes, No, }; unsigned OverEmptyLines; } I don't understand the need for `state` as a struct could have multiple options (as enums) each enum should have a state that means "Leave" Repository: rG LLVM Github Mo

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-09 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. > But you could set MaxEmptyLinesToKeep to 3 and aligning comments to over 2 > empty lines. Correct! lets assume MaxEmptyLinesToKeep = 3 if this case is valid in that case int a;// Foo int longer foo; // Foo int verylong foo; // Foo then so

[PATCH] D133571: [clang-format] Introduce NoFallThrough option into AllowShortCaseLabelsOnASingleLine

2022-09-09 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay created this revision. MyDeveloperDay added reviewers: HazardyKnusperkeks, owenpan, curdeius. MyDeveloperDay added a project: clang-format. Herald added a project: All. MyDeveloperDay requested review of this revision. Herald added a project: clang. As highlighted by https://github.

[PATCH] D133571: [clang-format] Introduce NoFallThrough option into AllowShortCaseLabelsOnASingleLine

2022-09-09 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 459024. MyDeveloperDay added a comment. self review CHANGES SINCE LAST ACTION https://reviews.llvm.org/D133571/new/ https://reviews.llvm.org/D133571 Files: clang/docs/ClangFormatStyleOptions.rst clang/include/clang/Format/Format.h clang/lib/

[PATCH] D133571: [clang-format] Introduce NoFallThrough option into AllowShortCaseLabelsOnASingleLine

2022-09-09 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 459074. MyDeveloperDay marked 3 inline comments as done. MyDeveloperDay added a comment. - rebase with fixed doc NFC update - rework the nofallback condition to prevent repeated checks - fix grammar checks CHANGES SINCE LAST ACTION https://reviews.l

[PATCH] D133589: [clang-format] JSON formatting add new option for controlling newlines in json arrays

2022-09-09 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay created this revision. MyDeveloperDay added reviewers: HazardyKnusperkeks, curdeius, owenpan. MyDeveloperDay added a project: clang-format. Herald added a project: All. MyDeveloperDay requested review of this revision. Herald added a project: clang. Working in a mixed environment of

[PATCH] D133589: [clang-format] JSON formatting add new option for controlling newlines in json arrays

2022-09-10 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 459283. MyDeveloperDay marked 7 inline comments as done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D133589/new/ https://reviews.llvm.org/D133589 Files: clang/.clang-format clang/docs/ClangFormatStyleOptions.rst clang/include/clang/For

[PATCH] D133589: [clang-format] JSON formatting add new option for controlling newlines in json arrays

2022-09-10 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. Addressed review comments, renamed the options Comment at: clang/docs/ClangFormatStyleOptions.rst:3115 +**JsonMultilineArrays** (``Boolean``) :versionbadge:`clang-format 16` + If ``true``, clang-format will always break after a Json array `[`

[PATCH] D133589: [clang-format] JSON formatting add new option for controlling newlines in json arrays

2022-09-10 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/docs/ClangFormatStyleOptions.rst:3115 +**JsonMultilineArrays** (``Boolean``) :versionbadge:`clang-format 16` + If ``true``, clang-format will always break after a Json array `[` MyDeveloperDay wrote: > cu

[PATCH] D133635: [clang-format] Don't insert braces for loops with a null statement

2022-09-10 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. Can't tell you how much I love this `InsertBraces` feature @ownpan, I work for a team (with a large code base) that uses them all the time, and we are catching missing braces in decade-old code! Thank you Repository: rG LLVM Github Monorepo CHANGES SINCE LAS

[PATCH] D133589: [clang-format] JSON formatting add new option for controlling newlines in json arrays

2022-09-12 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 459408. MyDeveloperDay added a comment. - address review comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D133589/new/ https://reviews.llvm.org/D133589 Files: clang/docs/ClangFormatStyleOptions.rst clang/include/clang/Format/Format.

[PATCH] D133589: [clang-format] JSON formatting add new option for controlling newlines in json arrays

2022-09-12 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay marked 6 inline comments as done. MyDeveloperDay added inline comments. Comment at: clang/include/clang/Format/Format.h:2076 + /// \version 16 + bool BreakArrays; + HazardyKnusperkeks wrote: > HazardyKnusperkeks wrote: > > Please sort. > What abo

[PATCH] D133571: [clang-format] Introduce NoFallThrough option into AllowShortCaseLabelsOnASingleLine

2022-09-12 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay marked an inline comment as done. MyDeveloperDay added inline comments. Comment at: clang/include/clang/Format/Format.h:469 + /// Different styles for merging short case labels. + enum ShortCaseLabelStyle : int8_t { +/// Never merge case code

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-12 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/include/clang/Format/Format.h:406 +/// Specifies the way to align trailing comments +TrailingCommentsAlignmentKinds Kind; +/// How many empty lines to apply alignment Kind? doesn't feel like the

[PATCH] D133589: [clang-format] JSON formatting add new option for controlling newlines in json arrays

2022-09-12 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay marked an inline comment as done. MyDeveloperDay added inline comments. Comment at: clang/lib/Format/Format.cpp:2190 Matching->is(TT_ArrayInitializerLSquare)) && -!(FormatTok->is(tok::r_brace) && Matching->is(TT_DictLiteral))) { +

[PATCH] D133589: [clang-format] JSON formatting add new option for controlling newlines in json arrays

2022-09-13 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 459712. MyDeveloperDay marked 4 inline comments as done. MyDeveloperDay added a comment. put back removed braces address other review comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D133589/new/ https://reviews.llvm.org/D133589 Files:

[PATCH] D129926: [clang-format] Handle constructor invocations after new operator in C# correct

2022-09-14 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a subscriber: aaron.ballman. MyDeveloperDay added a comment. @eoanermine ping... we need your name/email before we can commit. (@curdeius, @owenpan, @HazardyKnusperkeks ) we need to have a policy for this, that if we don't get the name for a commit we are happy to land, tha

[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

2022-09-14 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/include/clang/Format/Format.h:428 + +bool operator==(const TrailingCommentsAlignmentStyle &R) const { + return Kind == R.Kind && OverEmptyLines == R.OverEmptyLines; yusuke-kadowaki wrote: > MyDevelo

[PATCH] D127873: [clang-format] Fix misplacement of `*` in declaration of pointer to struct

2022-06-26 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. This revision is now accepted and ready to land. LGTM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D127873/new/ https://reviews.llvm.org/D127873 ___ cfe-commits mailing li

[PATCH] D128786: [clang-format] Fix incorrect isspace input (NFC)

2022-06-29 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128786/new/ https://reviews.llvm.org/D128786 ___

[PATCH] D128984: [clang-format] Tweak help text a bit

2022-07-02 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. This revision is now accepted and ready to land. LGTM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128984/new/ https://reviews.llvm.org/D128984 ___ cfe-commits mailing li

[PATCH] D129064: [clang-format] Avoid crash in LevelIndentTracker.

2022-07-04 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129064/new/ https://reviews.llvm.org/D129064 ___ cfe-commits mailing list cfe-com

[PATCH] D129057: [clang-format] Break on AfterColon only if not followed by comment

2022-07-04 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. LGTM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129057/new/ https://reviews.llvm.org/D129057 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.

[PATCH] D121451: [clang-format] Add space to comments starting with '#'.

2022-03-23 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. In D121451#3402167 , @curdeius wrote: > In D121451#3401947 , > @MyDeveloperDay wrote: > >> I'm a little uncomfortable with >> >> //# >> >> becoming >> >> // # >> >> At least wi

[PATCH] D122548: [clang-format] Don't format qualifiers in PPDirective

2022-03-27 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. LGTM thank you for the patch Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122548/new/ https://reviews.llvm.org/D122548 ___ cfe-comm

[PATCH] D131360: [clang-format] Fixes crash in QualifierOrder

2022-08-07 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay created this revision. MyDeveloperDay added reviewers: HazardyKnusperkeks, owenpan, curdeius. MyDeveloperDay added a project: clang-format. Herald added a project: All. MyDeveloperDay requested review of this revision. Prevent Null Token from causing a crash Fixes: https://github.c

[PATCH] D131360: [clang-format] Fixes crash in QualifierOrder

2022-08-07 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. Maybe I didn’t rebase correctly, let me retry and I’ll abandon if necessary, Thanks @owenpan for the pointer CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131360/new/ https://reviews.llvm.org/D131360 ___ cfe-c

[PATCH] D129926: [clang-format] Handle constructor invocations after new operator in C# correct

2022-08-07 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. Can we land this for you? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129926/new/ https://reviews.llvm.org/D129926 ___ cfe-commits

[PATCH] D130108: git-clang-format: format index not worktree when using --staged

2022-08-08 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. So trying to understand the problem statement, is it: 1. you have some files staged 2. and then you have to change them locally (review comment) 3. but forget to git add them, 4. you run git clang-format --staged 5. and it formats the new file (not added) based on

[PATCH] D106112: [clang-format] Break an unwrapped line at a K&R C parameter decl

2021-07-16 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. This revision is now accepted and ready to land. Thanks for this, LGTM, maybe give the others some time Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D106112/new/ https://reviews

[PATCH] D106112: [clang-format] Break an unwrapped line at a K&R C parameter decl

2021-07-16 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. In D106112#2883301 , @curdeius wrote: > Looks okay, but I was wondering if we don't want to guard all K&R-related > changes behind e.g. ```Standard: Cpp78``, so as not to possibly introduce > strange bugs in newer modes.

[PATCH] D106349: [clang-format] respect AfterEnum for enums

2021-07-21 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. This feels like there is some overlap with D93938: [clang-format] Fixed AfterEnum handling Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D106349/new/ https://reviews.llvm.org/D106349

[PATCH] D98214: [clang-format] Fix aligning with linebreaks

2021-07-23 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. In D98214#2900371 , @baramin wrote: > We have a regression after the fix: > CPP-25899 CLion formatting > does not match what clang-format produces > > if > > AlignConsecuti

[PATCH] D121269: [clang-format] Fix namepsace format when the name is after by a macro

2022-03-08 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay requested changes to this revision. MyDeveloperDay added inline comments. This revision now requires changes to proceed. Comment at: clang/lib/Format/NamespaceEndCommentsFixer.cpp:104 + } + if (!FirstNSTok->is(tok::coloncolon)) { +Name

[PATCH] D121269: [clang-format] Fix namepsace format when the name is after by a macro

2022-03-08 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Format/NamespaceEndCommentsFixer.cpp:104 + } + if (!FirstNSTok->is(tok::coloncolon)) { +NameFinished =

[PATCH] D121269: [clang-format] Fix namepsace format when the name is after by a macro

2022-03-08 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. Please wait for the other reviewers Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121269/new/ https://reviews.llvm.org/D121269 ___ cfe-commits mailing list cfe-commits@lis

[PATCH] D121451: [clang-format] Add space to comments starting with '#'.

2022-03-11 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. Is this conforming to `SpacesInLineCommentPrefix` Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121451/new/ https://reviews.llvm.org/D121451 ___ cfe-commits mailing list c

[PATCH] D121069: [clang-format] Minimize the damage caused by AlignArrayOfStructures when working on non square arrays

2022-03-12 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 414857. MyDeveloperDay marked 10 inline comments as done. MyDeveloperDay added a comment. Fixing final review comments prior to commit CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121069/new/ https://reviews.llvm.org/D121069 Files: clang/

[PATCH] D121069: [clang-format] Minimize the damage caused by AlignArrayOfStructures when working on non square arrays

2022-03-12 Thread MyDeveloperDay via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGadfe58b09df9: [clang-format] Minimize the damage caused by AlignArrayOfStructures when… (authored by MyDeveloperDay). Repository: rG LLVM Github M

[PATCH] D112019: [clang-format] [PR51412] AlignConsecutiveMacros fights with Visual Studio and resource.h

2022-03-13 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 414938. MyDeveloperDay marked 2 inline comments as done. MyDeveloperDay added a comment. Herald added a project: All. Address review comments and update for current trunk (up the first supported version in the documentation) CHANGES SINCE LAST ACTION

[PATCH] D112019: [clang-format] [PR51412] AlignConsecutiveMacros fights with Visual Studio and resource.h

2022-03-13 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay updated this revision to Diff 414950. MyDeveloperDay marked 2 inline comments as done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112019/new/ https://reviews.llvm.org/D112019 Files: clang/docs/ClangFormatStyleOptions.rst clang/include/clang/Format/Format.h clang/l

[PATCH] D112019: [clang-format] [PR51412] AlignConsecutiveMacros fights with Visual Studio and resource.h

2022-03-13 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. In D112019#3378024 , @HazardyKnusperkeks wrote: > Why limit to macros, could it be a member of AlignConsecutiveStyle and apply > to the other stuff as well? I personally don't have a use case other than the resource.h ca

[PATCH] D121576: [clang-format] Don't unwrap lines preceded by line comments

2022-03-14 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay accepted this revision. MyDeveloperDay added a comment. I'm wondering if the presence of the comment would impact the CellCount, I might go back and add some more unit tests for the "non rectangular" change I made. So this fixes the "}" going up onto the comment line, but not the

[PATCH] D121576: [clang-format] Don't unwrap lines preceded by line comments

2022-03-15 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. Please do, to be honest I spent enough time on this and I got to the same conclusion, it needs a rethink. Please go ahead, I don't use this feature myself so I'm not likely to see all the issues. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

<    3   4   5   6   7   8   9   10   11   12   >