Invalid suggestion for explicit_iter_loop
, which results in compiler error [trait bounds]
#4958
Labels
C-bug
Category: Clippy is not doing the correct thing
I-suggestion-causes-error
Issue: The suggestions provided by this Lint cause an ICE/error when applied
Code to reproduce the error
playground
Output from
clippy
:Following this suggestion would result in a compiler error:
playground
The correct suggestion would be to replace
iterator.into_iter()
withiterator
(which does make sense, because the for loop is syntax sugar for that)playground
The text was updated successfully, but these errors were encountered: