needless_question_mark
lint not applied to async fn
#8277
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
It seems like the
needless_question_mark
is not correctly applied toasync fn
, while it is applied to normal functions (obviously), and also async blocks correctly. See the reproduction below.Lint Name
needless_question_mark
Reproducer
I tried this code:
I expected to see this happen:
All three variants should trigger a
needless_question_mark
lint.Instead, this happened:
Only the
normal_fn
andasync_block
variants are triggering the lint.Version
The text was updated successfully, but these errors were encountered: