When struct_field_align_threshold is non-zero and trailing_comma is set to "Never," struct field separators are omitted between field groups. This issue is resolved by forcing separators between groups. Fixes #4791. A test is included with a minimal reproducible example.
15 lines
177 B
Rust
15 lines
177 B
Rust
// rustfmt-struct_field_align_threshold: 30
|
|
// rustfmt-trailing_comma: Never
|
|
|
|
struct Foo {
|
|
group_a: u8,
|
|
|
|
group_b: u8
|
|
}
|
|
|
|
struct Bar {
|
|
group_a: u8,
|
|
|
|
group_b: u8
|
|
}
|