Skip to content

Commit 446d650

Browse files
authored
Add a rustfmt.toml to the repository (#10809)
According to https://doc.rust-lang.org/nightly/edition-guide/rust-2024/rustfmt-style-edition.html#migration and https://github.com/rust-lang/rustfmt?tab=readme-ov-file#tips it's now "strongly recommended" to have `rustfmt.toml` with and edition configuration. This looks to be because `cargo fmt` reads the `edition` field in `Cargo.toml`, but running `rustfmt` directly doesn't do that. Editors often run `rustfmt` directly meaning they format differently than `cargo fmt` without this configuration.
1 parent be31168 commit 446d650

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

rustfmt.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
edition = '2024'

0 commit comments

Comments
 (0)