[PATCH] D125171: [clang-format] Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-06-13 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin added inline comments. Comment at: clang/unittests/Format/FormatTest.cpp:25716 + "int param2,\n" + "int param3);\n", + Style); H-G-Hristov wrote: > Does this work with `BAS_BlockIndent`? I don't see any re

[PATCH] D125171: [clang-format] Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-05-03 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 519293. jrmolin added a comment. more code review updates. pulled main. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125171/new/ https://reviews.llvm.org/D125171 Files: clang/docs/ClangFormatStyleOptions.rs

[PATCH] D125171: [clang-format] Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-04-24 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 516452. jrmolin added a comment. pulled upstream/main Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125171/new/ https://reviews.llvm.org/D125171 Files: clang/docs/ClangFormatStyleOptions.rst clang/include/

[PATCH] D125171: [clang-format] Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-04-24 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 516450. jrmolin marked an inline comment as done. jrmolin added a comment. change formatting of enum options Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125171/new/ https://reviews.llvm.org/D125171 Files:

[PATCH] D125171: [clang-format] Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-04-21 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin added inline comments. Comment at: clang/include/clang/Format/Format.h:851 + /// The function parameter breaking style to use. + /// \version 16.0 + FunctionParameterBreakingStyle BreakBeforeFunctionParameters; so should this be 17.0 now? This has gone

[PATCH] D125171: [clang-format] Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-04-21 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 515756. jrmolin added a comment. a unit test was failing, so I fixed it. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125171/new/ https://reviews.llvm.org/D125171 Files: clang/docs/ClangFormatStyleOptions.r

[PATCH] D125171: [clang-format] Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-04-14 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 513717. jrmolin marked 2 inline comments as done. jrmolin added a comment. there were a couple of bugs in the last patch that I missed. format tests all pass again with this one. I am using "Leave" as a transparent value, so no line breaks are added and none

[PATCH] D125171: [clang-format] Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-04-14 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin marked 4 inline comments as done. jrmolin added inline comments. Comment at: clang/lib/Format/Format.cpp:1336 LLVMStyle.AlwaysBreakAfterDefinitionReturnType = FormatStyle::DRTBS_None; + LLVMStyle.AlwaysBreakBeforeFunctionParameters = false; LLVMStyle.AlwaysBreakBef

[PATCH] D125171: [clang-format] Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-04-14 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 513610. jrmolin added a comment. changing the added option from a boolean to an enum that takes `Leave`, `Always`, and `Never`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125171/new/ https://reviews.llvm.or

[PATCH] D125171: [clang-format] Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-04-12 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin added a comment. In D125171#4261301 , @MyDeveloperDay wrote: > is it possible to point to a github issue that this related to in the review > summary, if not please can you make one so we can track the issue its trying > to solve added an issu

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-04-11 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 512480. jrmolin added a comment. fix a comment in the documentation Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125171/new/ https://reviews.llvm.org/D125171 Files: clang/docs/ClangFormatStyleOptions.rst

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-04-11 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 512449. jrmolin marked an inline comment as done. jrmolin added a comment. - updated the documentation to show the option works for function declaration and definition Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.o

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-04-11 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin marked 2 inline comments as done. jrmolin added inline comments. Comment at: clang/docs/ClangFormatStyleOptions.rst:1380 + Example uses + ``AlwaysBreakAfterReturnType`` set to ``All``. + MyDeveloperDay wrote: > This isn't relevant is it? `AlwaysBreakAft

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-04-11 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 512447. jrmolin marked 3 inline comments as done. jrmolin added a comment. - updated the tests to use long-form - added new tests to verify the no-parameter cases - updated the documentation to minimize formatting variables - ran the style guide generator Re

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-29 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin added a comment. In D125171#4230397 , @jrmolin wrote: > I think I have hit all the requests now. We're in the middle of building > release candidates and testing, so management is taking longer and longer to > get back to me about a style guide

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-29 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin added a comment. I think I have hit all the requests now. We're in the middle of building release candidates and testing, so management is taking longer and longer to get back to me about a style guide for my team. We added it, because it forces a consistent look across all function de

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-29 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 509317. jrmolin added a comment. ran the formatter, ran the documentation generator. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125171/new/ https://reviews.llvm.org/D125171 Files: clang/docs/ClangFormatSt

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-27 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin marked an inline comment as done. jrmolin added inline comments. Comment at: clang/lib/Format/TokenAnnotator.cpp:4742-4748 + if (Left.is(tok::l_paren) && Style.AlwaysBreakBeforeFunctionParameters && + !Right.is(tok::r_paren) && Left.Previous) { + const FormatTo

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-27 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 508639. jrmolin marked 2 inline comments as done. jrmolin added a comment. pulled main, re-generated the docs, then re-generated the diff. Also added a parse test and collapsed some nested `if` conditions. Repository: rG LLVM Github Monorepo CHANGES SINC

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-23 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin added a comment. In D125171#4215910 , @MyDeveloperDay wrote: > if you go ahead an rebase your should get rG7a5b95732ade: [clang-format] NFC > Format.h and ClangFormatStyleOptions.rst are out of date >

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-22 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin marked 4 inline comments as done. jrmolin added a comment. I still don't know what `Please write it out long form` means for the unit test. Comment at: clang/docs/ClangFormatStyleOptions.rst:3663 +.. _Macros: + I didn't modify this section in the head

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-22 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 507539. jrmolin added a comment. I updated the code comment in Format.h and ran the docs generator. I didn't modify the Macros section, but that got updated when I ran the docs generator. We don't have a published style guide, unfortunately. I can work towar

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-15 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin added a comment. In D125171#4195298 , @owenpan wrote: > In D125171#4193996 , @jrmolin wrote: > >> In D125171#4167866 , @owenpan >> wrote: >> >>> Please see >>> h

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-14 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 505215. jrmolin marked 3 inline comments as done. jrmolin added a comment. respond to code review requests/comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125171/new/ https://reviews.llvm.org/D125171 Fi

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-14 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin marked 4 inline comments as done. jrmolin added inline comments. Comment at: clang/include/clang/Format/Format.h:827 + /// \code + /// someFunction( + /// int argument1, HazardyKnusperkeks wrote: > That's not a valid declaration (missing return

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-14 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin added a comment. In D125171#4167866 , @owenpan wrote: > Please see > https://clang.llvm.org/docs/ClangFormatStyleOptions.html#adding-additional-style-options. I am doing this for my team, which writes the security endpoint for Elastic Defend. T

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-03 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 502112. jrmolin added a comment. Finally figured out how to run the latest `git-clang-format` on the code Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125171/new/ https://reviews.llvm.org/D125171 Files: cla

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-02 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin added reviewers: MyDeveloperDay, owenpan. jrmolin added a comment. I finally found the correct CodeOwners.rst file. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125171/new/ https://reviews.llvm.org/D125171

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-02 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin updated this revision to Diff 501836. jrmolin added a comment. Updated the version string in the docs and pulled in main. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125171/new/ https://reviews.llvm.org/D125171 Files: clang/docs/ClangF

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2022-05-07 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin created this revision. Herald added a project: All. jrmolin requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Add the definition, documentation, and implementation for a new clang-format option. Repository: rG LLVM Github Monorep