Uh oh!
There was an error while loading. Please reload this page.
lints_that_dont_need_to_run: never skip future-compat-reported lints - #133108
Conversation
rustbot
commented
Nov 16, 2024
| let has_future_breakage = | ||
| lint.future_incompatible.is_some_and(|fut| fut.reason.has_future_breakage()); | ||
| !has_future_breakage && !lint.eval_always | ||
| }) |
There was a problem hiding this comment.
Is there a reason to have these two as different methods?
There was a problem hiding this comment.
I think it's easier to first do the pure filtering, and then the filter_map part that also transforms the data. This also reduces rightward drift in the filter_map closure.
There was a problem hiding this comment.
could the fitire breakage check be moved earlier? i.e. automatically set eval_always for all future breakage lints
There was a problem hiding this comment.
That would require putting the logic for this into the declare_lint macro. IMO that's a bad idea, I'd rather not have this logic hidden in a macro.
Uh oh!
There was an error while loading. Please reload this page.
lcnr
commented
Nov 19, 2024
r=me after nit |
e7d2d4c to
df94818CompareRalfJung
commented
Nov 19, 2024
@bors r=lcnr |
bors
commented
Nov 19, 2024
Rollup of 5 pull requests Successful merges: - rust-lang#132732 (Use attributes for `dangling_pointers_from_temporaries` lint) - rust-lang#133108 (lints_that_dont_need_to_run: never skip future-compat-reported lints) - rust-lang#133190 (CI: use free runner in dist-aarch64-msvc) - rust-lang#133196 (Make rustc --explain compatible with BusyBox less) - rust-lang#133216 (Implement `~const Fn` trait goal in the new solver) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#133108 - RalfJung:future-compat-needs-to-run, r=lcnr lints_that_dont_need_to_run: never skip future-compat-reported lints Follow-up to rust-lang#125116: future-compat lints show up with `--json=future-incompat` even if they are otherwise allowed in the crate. So let's ensure we do not skip those as part of the `lints_that_dont_need_to_run` logic. I could not find a current future compat lint that is emitted by a lint pass, so there's no clear way to add a test for this. Cc `@blyxyas` `@cjgillot`
Follow-up to #125116: future-compat lints show up with
--json=future-incompateven if they are otherwise allowed in the crate. So let's ensure we do not skip those as part of thelints_that_dont_need_to_runlogic.I could not find a current future compat lint that is emitted by a lint pass, so there's no clear way to add a test for this.
Cc @blyxyas@cjgillot