- Notifications
You must be signed in to change notification settings - Fork 1.8k
Open
Labels
C-feature-requestCategory: Feature requestCategory: Feature request
Description
Summary
The justification for the let_underscore_untyped
lint seems to apply when _
is used without a let
binding. I realize this means the use of _
is impossible with this lint, but that's not uncommon for restriction
lints.
#![expect(dead_code, reason = "illustrative example")] #![deny(clippy::let_underscore_untyped, reason = "illustrative example")] fn bar() { // Doesn't this suffer from the same drawbacks as `let _ = foo();`? _ = foo(); // Uncommenting below will cause a compile error due to the `let_underscore_untyped` lint. // let _ = foo(); } fn foo() -> Result<(), u32> { Ok(()) }
Metadata
Metadata
Assignees
Labels
C-feature-requestCategory: Feature requestCategory: Feature request