rust-clippy icon indicating copy to clipboard operation
rust-clippy copied to clipboard

Minimal nightly-only lints

Open Jarcho opened this issue 1 year ago • 0 comments

This uses is_nightly_build to determine if nightly-only lints should be added to their category, but makes no other changes. This means nightly-only lints are still registered and running, but they will no longer be enabled by default on beta and stable, nor will they be effected by their group name (e.g. #![warn(clippy::pedantic)]).

This accomplishes the main goal of preventing high false-positive rates from leaking out of the nightly release while still allowing the lints to be well tested there. Changes outside clippy are also not required to make this work, which I think any other approach requires.

Any nightly-only lint can still be run on stable, and any ICE's from them will still leak through. I don't think the first one is a problem as the lint has to be specifically named. The latter is an unfortunate problem, but I don't think that's avoidable without a much larger code change.

r? @flip1995

Jarcho avatar Aug 12 '22 02:08 Jarcho