Open
Description
Coming from #3373.
There seems to be an issue which sometimes occurs whenever these two options are present at the same time in a rustfmt configuration:
control_brace_style = 'AlwaysNextLine'
match_arm_blocks = false
For example, take the following snippet from a cargo new
main.rs file:
fn main() {
let fooooooo = "100000000000000000000000";
let _bar = match fooooooo {
"100000000000000000000000" => fooooooo.len() == 1 && fooooooo.contains("222222222222222222"),
_ => unreachable!("Should not happen"),
};
}
Running cargo fmt
on this code results in the following error:
error[internal]: left behind trailing whitespace
--> /home/iron-e/Programming/ACTIVE/rustfmt-error-example/src/main.rs:6:6:1
|
6 |
| ^^^^^^^^
|
warning: rustfmt has failed to format. See previous 1 errors.
It seems that line 4 of the snippet being >=95 characters long has something to do with it. The rest of the code is just filler to get it to compile.