Prevent `missing_const_for_fn` on functions with const generic params
`const` functions cannot have const generic parameters so prevent the
`missing_const_for_fn` lint from firing in that case.
changelog: Fix false positive in `missing_const_for_fn`
Fixes#5192
New Lint: `wildcard imports`
Fixes#1228
### A few notes:
- I put this lint in the pedantic group, even though in the issue restriction was mentioned.
- Every fallout fix was automatically applied by `cargo fix` (This produced 3 `unused_imports` warnings) and are in commit 7e834c8. So reverting these changes wouldn't be a problem.
### A few ideas:
- A configuration to specify the amount of imported Items, where a `*` might be better.
- ~~A configuration to disable the lint for enums. Or just disable the lint for enums, since there is [`enum_glob_use`](https://rust-lang.github.io/rust-clippy/master/index.html#enum_glob_use)~~ I moved `enum_glob_use` into this lint in 12937f0
### A few quotes from the issue:
> Is there a way to ask the compiler about the modules or symbols that the current file is using?
Yes there is. I found it, once I was nearly finished implementing it myself. See 321d64a
> one hard optional feature would be to figure out what is currently used and add a suggestion to replace it with a full import list.
Yeah that was pretty hard, until I found the query for this. Queries are cool, but too hard to find.
> FWIW VS Code and Intellij IDEA both offer imports deglobbing which replace * with required imports.
And now, Clippy can do this too! 🎉
---
Your thoughts on the notes/ideas?
changelog: Add new lint [`wildcard imports`]. Add suggestion to [`enum_glob_use`]
Move check for lossy whole-number floats out of `excessive_precision`
changelog: Add new lint `lossy_float_literal` to detect lossy whole number float literals and move it out of `excessive_precision` again.
Fixes#5201
Update License
r? @Manishearth
I'm not sure if the Copyright claim was left out on purpose in the LICENSE-* files. I added them, because the official templates have them.
changelog: none
redundant_clone: Migrate to new dataflow framework
Migration to [the new dataflow framework](https://github.com/rust-lang/rust/pull/65672) is ongoing in rustc. This PR updates the dataflow impl in `redundant_clone` lint.
---
changelog: none
I like to move it, move it
GHA now runs in the background for 6 days (#5088)
Since then ~~15~~ 19 PRs were successfully merged and Travis+Appveyor agreed on the status in every case. ([GitHub PR search query](https://github.com/rust-lang/rust-clippy/pulls?utf8=%E2%9C%93&q=is%3Apr+is%3Amerged+merged%3A%3E%3D2020-02-12T15%3A42%3A00+sort%3Aupdated-desc+NOT+%5Bgh-pages%5D+in%3Atitle))
Some PRs were:
- #5163
- #5170
- #5168
- #5173
- #5171
- #5156
- #4809
- #5177
- #5182
- #5183
- #5184
- #5185
- #5186
- #5181
- #5189
Bug with GHA:
- When a rustc PR gets merged between the `integration_build` and the `integration` job, the `integration` job will fail. This happened once in #5162, but not in the past 6 days. Even if it would happen every 4th PR we would save time, since splitting up the integration build and tests saves 5-7 minutes per run and a complete run takes 15-17 minutes
- Sometimes the MacOS build takes up to an hour to download the master toolchain. Until now, this happend 2 or 3 times and can be resolved by a `@bors r3try`+canceling the previous run (restarting single jobs is not supported yet)
## Before merging this, https://github.com/rust-lang/rust-central-station/pull/578 has to get merged
This PR is for starting the discussion and to get consensus (@rust-lang/clippy) on a final move to GHA. If we're ready, I'll contact Pietro, to finalize the move.
changelog: Clippy completely runs on GHA now 🎉
---
BTW: The deployment already runs on GHA, instead of Travis.
Expand `missing_errors_doc` to also work on async functions
This adds the `missing_errors_doc` lint to async functions.
changelog: Make [`missing_errors_doc`] lint also trigger on `async` functions