dependency_on_unit_never_type_fallback bad suggestion with APIT generics #133842
Labels
A-edition-2024
Area: The 2024 edition
A-lints
Area: Lints (warnings about flaws in source code) such as unused_mut.
A-suggestion-diagnostics
Area: Suggestions generated by the compiler applied by `cargo fix`
C-bug
Category: This is a bug.
D-edition
Diagnostics: An error or lint that should account for edition differences.
D-invalid-suggestion
Diagnostics: A structured suggestion resulting in incorrect code.
L-dependency_on_unit_never_type_fallback
Lint: dependency_on_unit_never_type_fallback
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
The
dependency_on_unit_never_type_fallback
lint seems to provide a bad suggestion to include too many generic arguments when the function being called uses APIT. Example:Here this suggests the following change:
However, this fails to compile because the function only takes one generic argument. The correct suggestion would be just
::<()>
.Meta
The text was updated successfully, but these errors were encountered: