mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-30 10:45:18 +00:00
Allow --edition 2021
to be passed to rustfmt
This was added to Configurations.md in #4618, but the option wasn't actually made available. This should let people who are using Rust 2021 on nightly rustc run `cargo fmt` again.
This commit is contained in:
parent
bfd479d5af
commit
75765f656e
@ -689,6 +689,7 @@ fn edition_from_edition_str(edition_str: &str) -> Result<Edition> {
|
|||||||
match edition_str {
|
match edition_str {
|
||||||
"2015" => Ok(Edition::Edition2015),
|
"2015" => Ok(Edition::Edition2015),
|
||||||
"2018" => Ok(Edition::Edition2018),
|
"2018" => Ok(Edition::Edition2018),
|
||||||
|
"2021" => Ok(Edition::Edition2021),
|
||||||
_ => Err(format_err!("Invalid value for `--edition`")),
|
_ => Err(format_err!("Invalid value for `--edition`")),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user