[PATCH] D14484: [clang-format] Formatting constructor initializer lists by putting them always on different lines

Timo Suoranta via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun May 30 01:54:56 PDT 2021


tksuoran added a comment.

I would like to use exactly the same formatting (really exactly one initializer (and nother else) per line). 
Some comments:

- Keep `ConstructorInitializerAllOnOneLineOrOnePerLine` so that the change does not break any existing behavior
- Default value for `ConstructorInitializerKind` would make `ConstructorInitializerAllOnOneLineOrOnePerLine` to be used
- Non-default values for `ConstructorInitializerKind` would enable for example really exactly one initializer per line - yay!
- End result:
  - Old style settings keep working and it just works, giving old results
  - New style settings can omit  `ConstructorInitializerAllOnOneLineOrOnePerLine` and use `ConstructorInitializerKind` and it just works


Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D14484/new/

https://reviews.llvm.org/D14484



More information about the llvm-commits mailing list