unused-peekable can trigger when peek() is used #9456
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
In some cases
unused-peekable
triggers when having aPeekable<_>
is required to satisfy the interface of some other functionLint Name
unused-peekable
Reproducer
I tried this code:
I saw this happen:
I expected to see this happen:
No error: having a
Peekable
is required to satisfyPauseAt::from_peekable
interface (andpeek()
is called, indirectly)Version
Additional Labels
No response
The text was updated successfully, but these errors were encountered: