Skip to content

Internal error when trying to format code with inline block comment #6200

Open
@Sorseg

Description

@Sorseg

When formatting this file
cargo +nightly fmt does not modify the file and reports this error:

error[internal]: left behind trailing whitespace
   --> <...>/riano/src/main.rs:353:353:58
    |
353 |                                     piano.sustain = true; 
    |                                                          ^
    |

warning: rustfmt has failed to format. See previous 1 errors.
$ cargo +nightly fmt --version
rustfmt 1.7.0-nightly (59e2c01 2024-06-17)

Removing the block comment on this line allows rustfmt to format the file again.

Thank you for maintaining this! 🧡

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions