Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"version option is deprecated", but documented as valid #6401

Closed
ethanmsl opened this issue Nov 21, 2024 · 1 comment
Closed

"version option is deprecated", but documented as valid #6401

ethanmsl opened this issue Nov 21, 2024 · 1 comment

Comments

@ethanmsl
Copy link

ethanmsl commented Nov 21, 2024

rustfmt.toml contains the following line:

version = "Two"

When I run cargo fmt I get the following warning:

Warning: the version` option is deprecated. Use `style_edition` instead.

However, the "version" is documented in this github repo's documentation here:
Configuring rustfmt: version

version

Which version of the formatting rules to use. Version::One is backwards-compatible with Rustfmt > 1.0. Other versions are only backwards compatible within a major version number.

Default value: One
Possible values: One, Two
Stable: No (tracking issue: #3383)

But there is no entry for "style_edition".

However, looking at the tracing issue listed above (3383) we see that "version" is now listed as "not planned".


This may simply be a matter of needing to link to up-to-date docs on the github site, but bears mentioning.

Edit: Ah, I see, the link defaults to v1.6. Perhaps that's reasonable. I'm on nightly and this may be the source of confusion. I'm not sure what version stable uses.
Image

@ytmimi
Copy link
Contributor

ytmimi commented Nov 21, 2024

Yeah, style_edition is documented in v1.8.0. A more detailed description of how style_edition relates to version can be found here.

@ytmimi ytmimi closed this as not planned Won't fix, can't repro, duplicate, stale Nov 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants