needless_return
has false negative pattern
#8978
Labels
C-bug
Category: Clippy is not doing the correct thing
I-false-negative
Issue: The lint should have been triggered on code, but wasn't
Summary
There is a pattern that does not work even though needless_return is enabled.
playground is here.
Lint Name
needless_return
Reproducer
I tried this code:
I expected to see this happen: There should be a suggestion as above follows.
Instead, this happened: No happen.
Version
The text was updated successfully, but these errors were encountered: