File tree 2 files changed +8
-4
lines changed
2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -3105,9 +3105,9 @@ fn main() {
3105
3105
3106
3106
## ` version `
3107
3107
3108
- Which version of the formatting rules to use. ` Version::One ` is backwards-compatible
3109
- with Rustfmt 1.0. Other versions are only backwards compatible within a major
3110
- version number.
3108
+ This option is deprecated and has been replaced by [ ` style_edition ` ] ( #style_edition ) .
3109
+ ` version = "One" ` is equivalent to ` style_edition = "(2015|2018|2021)" ` and
3110
+ ` version = "Two" ` is equivalent to ` style_edition = "2024" `
3111
3111
3112
3112
- ** Default value** : ` One `
3113
3113
- ** Possible values** : ` One ` , ` Two `
Original file line number Diff line number Diff line change @@ -571,7 +571,11 @@ macro_rules! create_config {
571
571
572
572
eprintln!(
573
573
"Warning: the `version` option is deprecated. \
574
- Use `style_edition` instead."
574
+ Use `style_edition=\" {0}\" ` instead.",
575
+ match self . version. 2 {
576
+ Version :: One => "2015" ,
577
+ Version :: Two => "2024" ,
578
+ }
575
579
) ;
576
580
577
581
if self . was_set( ) . style_edition( ) || self . was_set_cli( ) . style_edition( ) {
You can’t perform that action at this time.
0 commit comments