[clang] [clang-format] Add option to omit wrapping for empty records (PR #151970)
Björn Schäpers via cfe-commits
cfe-commits at lists.llvm.org
Mon Aug 11 06:41:40 PDT 2025
================
@@ -1355,6 +1355,32 @@ struct FormatStyle {
BWACS_Always
};
+ enum BraceWrapEmptyRecordStyle : int8_t {
+ /// Use default wrapping rules for records
+ /// (AfterClass,AfterStruct,AfterUnion)
+ /// \code
+ /// class foo
+ /// {
+ /// int foo;
+ /// };
+ ///
+ /// class foo
+ /// {
+ /// };
+ /// \endcode
+ BWER_Default,
+ /// Override wrapping for empty records
----------------
HazardyKnusperkeks wrote:
```suggestion
/// Override wrapping for empty records.
```
https://github.com/llvm/llvm-project/pull/151970
More information about the cfe-commits
mailing list