-
Notifications
You must be signed in to change notification settings - Fork 2k
Weird clippy suggestion #15589
Copy link
Copy link
Closed
Labels
C-bugCategory: Clippy is not doing the correct thingCategory: Clippy is not doing the correct thingI-false-positiveIssue: The lint was triggered on code it shouldn't haveIssue: The lint was triggered on code it shouldn't have
Metadata
Metadata
Assignees
Labels
C-bugCategory: Clippy is not doing the correct thingCategory: Clippy is not doing the correct thingI-false-positiveIssue: The lint was triggered on code it shouldn't haveIssue: The lint was triggered on code it shouldn't have
Type
Fields
Give feedbackNo fields configured for issues without a type.
Summary
It might just be me but this clippy lint feels wrong.
Lint Name
clippy::collapsible_if
Reproducer
POC
Now that if-let-chains are stabilized, it should suggest something like this:
IMO For older rust versions, it souldn't suggest anything if one of the if statements is a
if let.Version
Additional Labels
No response