I am getting error[internal]: left behind trailing whitespace on the latest stable 1.90 and nightly rustc 1.92.0-nightly (4645a7988 2025-09-17)
Minimum example: https://play.rust-lang.org/?version=stable&mode=debug&edition=2024&gist=67d8495779f0d47760dff7bea024ad75
fn main() {
match () /*x*/ {
_ => {}
}
}
The issue is caused by the comment after the scrutinee. If you remove the x (but keep the /**/), it will format, or if you replace x with any number of spaces, it formats fine.
Also fails if scrutinee is a variable name.
I am getting
error[internal]: left behind trailing whitespaceon the latest stable 1.90 and nightlyrustc 1.92.0-nightly (4645a7988 2025-09-17)Minimum example: https://play.rust-lang.org/?version=stable&mode=debug&edition=2024&gist=67d8495779f0d47760dff7bea024ad75
The issue is caused by the comment after the scrutinee. If you remove the
x(but keep the/**/), it will format, or if you replacexwith any number of spaces, it formats fine.Also fails if scrutinee is a variable name.