fix various clippy lints from 1.57

This commit is contained in:
Antoine Martin 2021-12-04 16:55:40 +01:00
parent 239247a8c6
commit d7a77e9283
4 changed files with 6 additions and 21 deletions

View file

@ -84,12 +84,12 @@ impl FromStr for Image {
let lines = digits
.chunks(IMG_WIDTH)
.map(|chunk| chunk.to_vec())
.map(<[_]>::to_vec)
.collect::<Vec<Vec<u8>>>();
let layers = lines
.chunks(IMG_HEIGHT)
.map(|chunk| chunk.to_vec())
.map(<[_]>::to_vec)
.map(|pixels| Layer { pixels })
.collect::<Vec<Layer>>();