Closed
Description
Lint name: map_identity
I tried this code: (Originally posted by @coolreader18 in RustPython/RustPython#2627 (comment))
self.dict
.entries
.next_entry(&mut self.position)
.map(|(key, value)| (key, value))
I expected to see this happen: Clippy recognizing that this map is an identity function.
Instead, this happened: Clippy has no comment.
Meta
cargo clippy -V
: clippy 0.1.52 (88f19c6 2021-05-03)rustc -Vv
:rustc 1.46.0-nightly (f455e46ea 2020-06-20) binary: rustc commit-hash: f455e46eae1a227d735091091144601b467e1565 commit-date: 2020-06-20 host: x86_64-unknown-linux-gnu release: 1.46.0-nightly LLVM version: 10.0