mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-26 08:44:35 +00:00
67a9f20c91
`cloned` requires that the elements of the iterator must be references. This change determines if that is the case by examining the type of the closure argument and suggesting `.cloned` only if it is a reference. When the closure argument is not a reference, it suggests removing the `map` call instead. A minor problem with this change is that the new check sometimes overlaps with the `clone_on_copy` lint. Fixes #498 |
||
---|---|---|
.. | ||
auxiliary | ||
run-pass | ||
ui | ||
ui-toml | ||
compile-test.rs | ||
dogfood.rs | ||
matches.rs | ||
needless_continue_helpers.rs | ||
versioncheck.rs |