You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[clang-format] Add option to omit wrapping for empty records
Currently, clang-format does not allow empty records to be formatted
on a single line if the corresponding `BraceWrapping.After*` option
is set to true.
This results in unnecessarily wrapped code:
struct foo
{
int i;
};
struct bar
{
};
This patch adds the `BraceWrapping.WrapEmptyRecord` option, which
allows `class`, `struct`, and `union` declarations with empty bodies
to be formatted as one-liners, even when `AfterRecord: true`.
As such, the following becomes possible:
struct foo
{
int i;
};
struct bar {};
0 commit comments