RS.CLIPPY.DEPRECATED_CLIPPY_CFG_ATTR

Usage of `cfg(feature = \"cargo-clippy\")` instead of `cfg(clippy)`

This checker is a Clippy lint created by The Rust Project Contributors. The documentation shown here is a copy of the original documentation for: deprecated_clippy_cfg_attr. Copyright ©2025 The Rust Team. All rights reserved.

What it does

Checks for #[cfg_attr(feature = "cargo-clippy", ...)] and for #[cfg(feature = "cargo-clippy")] and suggests to replace it with #[cfg_attr(clippy, ...)] or #[cfg(clippy)].

Why is this bad?

This feature has been deprecated for years and shouldn't be used anymore.

Example

#[cfg(feature = "cargo-clippy")]
struct Bar;

Use instead:

#[cfg(clippy)]
struct Bar;