-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Open
Labels
A-lintArea: New lintsArea: New lintsL-unnecessaryLint: Warn about unnecessary codeLint: Warn about unnecessary code
Description
As featured in this Twitter poll.
A statement of the form let _ = <place>
has no effect (modulo Deref coersion) as the place is not moved from. This should instead be omited (if all Deref coersion is pure) or otherwise written to be more clear on intent (explicitly calling side-effectful Deref).
50% of people had the wrong intuition of behavior here, so this definitely would help avoid potentially misleading code.
DobromirM
Metadata
Metadata
Assignees
Labels
A-lintArea: New lintsArea: New lintsL-unnecessaryLint: Warn about unnecessary codeLint: Warn about unnecessary code