Add a minimal reproducer for the ICE in #6179
This PR is an auxiliary PR for #6179, just add a minimal reproducer for the ICE discussed in #6179.
See #6179 for more details.
changelog: none
lintcheck: accept env var to set crates.toml file
*Please write a short comment explaining your change (or "none" for internal only changes)*
changelog: lintcheck: accept LINTCHECK_TOML env var to set list of crates to be checked.
Rework use_self impl based on ty::Ty comparison #3410 | Take 2
This builds on top of #5531
I already reviewed and approved the commits by `@montrivo.` So only the review of my commits should be necessary.
I would also appreciate your review `@montrivo,` since you are familiar with the challenges here.
Fixes#3410 and Fixes#4143 (same problem)
Fixes#2843Fixes#3859Fixes#4734 and fixes#6221Fixes#4305Fixes#5078 (even at expression level now 🎉)
Fixes#3881 and Fixes#4887 (same problem)
Fixes#3909
Not yet: #4140 (test added)
All the credit for the fixes goes to `@montrivo.` I only refactored and copy and pasted his code.
changelog: rewrite [`use_self`] lint and fix multiple (8) FPs. One to go.
some more lintcheck changes
* Explain why tokei is commented out in the lintcheck sources.
* If we specify a custom sources.toml, don't override the preexisting lintcheck logs, but rather start a new log with the filename depending on the sources.toml name.
* Start adding a readme.md to clippy_dev and add some information on how to use the lintcheck subcommand.
* Add support for path/local sources (I needed this for the next item which is: )
* Collect ICEs that happen while clippy checks crates
changelog: more lintcheck changes
Fix suggestions that need parens in `from_iter_instead_of_collect` lint
Fixes broken suggestions that need parens (i.e.: range)
Fixes: #6648
changelog: none
Stabilize workspace wrapper.
This fixes it so that `cargo clippy` doesn't share the same cache artifacts as `cargo check`. The Cargo side was stabilized a while ago (https://github.com/rust-lang/cargo/pull/8976), so this should be ready to go. I'm not aware of any blockers or concerns.
Closes#4612
---
changelog: `cargo clippy` no longer shares the same build cache as `cargo check`.
This renames the variants in HIR UnOp from
enum UnOp {
UnDeref,
UnNot,
UnNeg,
}
to
enum UnOp {
Deref,
Not,
Neg,
}
Motivations:
- This is more consistent with the rest of the code base where most enum
variants don't have a prefix.
- These variants are never used without the `UnOp` prefix so the extra
`Un` prefix doesn't help with readability. E.g. we don't have any
`UnDeref`s in the code, we only have `UnOp::UnDeref`.
- MIR `UnOp` type variants don't have a prefix so this is more
consistent with MIR types.
- "un" prefix reads like "inverse" or "reverse", so as a beginner in
rustc code base when I see "UnDeref" what comes to my mind is
something like "&*" instead of just "*".