manual_filter triggered if you return Some(-x) #10125
Labels
C-bug
Category: Clippy is not doing the correct thing
I-false-positive
Issue: The lint was triggered on code it shouldn't have
Summary
I'm getting
error: manual implementation of `Option::filter`
even though the code isn't filtering as it returnSome(-x)
notSome(x)
Lint Name
manual_filter
Reproducer
I tried this code:
I saw this happen:
I expected to see this happen:
It to find nothing wrong like it did before I updated Clippy
Version
Additional Labels
No response
The text was updated successfully, but these errors were encountered: