[clang] [clang-format] Add BreakFunctionDeclarationParameters option (PR #158745)

2025-09-20 Thread via cfe-commits
@@ -8143,6 +8143,39 @@ TEST_F(FormatTest, BreakFunctionDefinitionParameters) { Input, Style); } +TEST_F(FormatTest, BreakFunctionDeclarationParameters) { + StringRef Input = "void functionDecl(paramA, paramB, paramC);\n" +"void emptyFunction

[clang] [clang-format] Add BreakFunctionDeclarationParameters option (PR #158745)

2025-09-16 Thread via cfe-commits
@@ -2389,6 +2389,20 @@ struct FormatStyle { /// \version 19 bool BreakFunctionDefinitionParameters; + /// If ``true``, clang-format will always break before function declaration + /// parameters. + /// \code + ///true: + ///void functionDeclaration( + ///

[clang] [clang-format] Add BreakFunctionDeclarationParameters option (PR #158745)

2025-09-15 Thread via cfe-commits
github-actions[bot] wrote: Thank you for submitting a Pull Request (PR) to the LLVM Project! This PR will be automatically labeled and the relevant teams will be notified. If you wish to, you can add reviewers by using the "Reviewers" section on this page. If this is not working for you, it

[clang] [clang-format] Add BreakFunctionDeclarationParameters option (PR #158745)

2025-09-15 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Fanteria (Fanteria) Changes Add a new clang-format option `BreakFunctionDeclarationParameters` to control whether parameters in function declarations can be broken onto new lines, similar to the existing `BreakFunctionDefinitionPar

[clang] [clang-format] Add BreakFunctionDeclarationParameters option (PR #158745)

2025-09-15 Thread via cfe-commits
https://github.com/Fanteria created https://github.com/llvm/llvm-project/pull/158745 Add a new clang-format option `BreakFunctionDeclarationParameters` to control whether parameters in function declarations can be broken onto new lines, similar to the existing `BreakFunctionDefinitionParameter