Skip to content

Commit d2436f0

Browse files
flip1995Mark-Simulacrum
authored andcommitted
Clippy post: clarify that only nightly is affected for now
1 parent 65078d5 commit d2436f0

File tree

1 file changed

+11
-5
lines changed

1 file changed

+11
-5
lines changed

posts/2024-02-28-Clippy-deprecating-feature-cargo-clippy.md

+11-5
Original file line numberDiff line numberDiff line change
@@ -28,23 +28,29 @@ lint levels with tool lint attributes using the `clippy::` prefix:
2828
```
2929

3030
The implicit `feature = "cargo-clippy"` has only been kept for backwards
31-
compatibility, but will now be deprecated.
31+
compatibility, but will be deprecated in upcoming nightlies and later in
32+
`1.78.0`.
3233

3334
## Alternative
3435

3536
As there is a rare [use case] for conditional compilation depending on Clippy,
36-
we will provide an alternative. So in the future you will be able to use:
37+
we will provide an alternative. So in the future (`1.78.0`) you will be able to
38+
use:
3739

3840
```rust
3941
#[cfg(clippy)]
4042
```
4143

4244
## Transitioning
4345

46+
> Should you only use stable toolchains, you can wait with the transition until
47+
> Rust `1.78.0` (2024-05-02) is released.
48+
4449
Should you have instances of `feature = "cargo-clippy"` in your code base, you
4550
will see a warning from the new Clippy lint
46-
[`clippy::deprecated_clippy_cfg_attr`][pr-12292]. This lint can automatically fix
47-
your code. So if you should see this lint triggering, just run:
51+
[`clippy::deprecated_clippy_cfg_attr`] available in the latest nightly Clippy.
52+
This lint can automatically fix your code. So if you should see this lint
53+
triggering, just run:
4854

4955
```
5056
cargo clippy --fix -- -Aclippy::all -Wclippy::deprecated_clippy_cfg_attr
@@ -85,6 +91,6 @@ deprecate the implicit `feature = "cargo-clippy"` config and replace it with the
8591
[`v0.0.97`]: https://github.com/rust-lang/rust-clippy/blob/61daf674eaf17f3b504c51f01b4ee63fac47dfcf/CHANGELOG.md?plain=0#0097--2016-11-03
8692
[rfc-3013]: https://github.com/rust-lang/rfcs/pull/3013
8793
[use case]: https://doc.rust-lang.org/clippy/configuration.html#disabling-evaluation-of-certain-code
88-
[pr-12292]: https://github.com/rust-lang/rust-clippy/pull/12292
94+
[`clippy::deprecated_clippy_cfg_attr`]: https://rust-lang.github.io/rust-clippy/master/index.html#/deprecated_clippy_cfg_attr
8995
[cargo-lints]: https://doc.rust-lang.org/cargo/reference/manifest.html#the-lints-section
9096
[call for testing]: https://github.com/rust-lang/rfcs/pull/3013#issuecomment-1936648479

0 commit comments

Comments
 (0)