]> git.lizzy.rs Git - rust.git/commit
Auto merge of #8382 - tamaroning:suggest_iter_instead_of_into_iter, r=giraffate
authorbors <bors@rust-lang.org>
Wed, 2 Feb 2022 12:37:18 +0000 (12:37 +0000)
committerbors <bors@rust-lang.org>
Wed, 2 Feb 2022 12:37:18 +0000 (12:37 +0000)
commitbef92b864d3591cffbee23ea88461b26af0b4d75
tree7f4929c6846b310c056d250c107aa721cb6dcc0e
parentcf53710744e2a4868f4c6015ea7be15cd8087a45
parentf5fd9ded000d7968b6641d2b17f4eca53a4a8f67
Auto merge of #8382 - tamaroning:suggest_iter_instead_of_into_iter, r=giraffate

[explicit_counter_loop] suggests `.into_iter()`, despite that triggering [into_iter_on_ref] in some cases

I have modified `fn make_iterator_snippet` in clippy_lints/src/loops/utils.rs ,so this change has some little influence on another lint [manual_flatten] .

fixes #8155

---
changelog: Fix that [`explicit_counter_loop`] suggests `into_iter()` despite that triggering [`into_iter_on_ref`] in some cases