[INFO] cloning repository https://github.com/sthilden/advent_of_code [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/sthilden/advent_of_code" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsthilden%2Fadvent_of_code", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsthilden%2Fadvent_of_code'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] fe5054dfbb044bef1039272a63a67080e9376a33 [INFO] linting sthilden/advent_of_code against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsthilden%2Fadvent_of_code" "/workspace/builds/worker-4-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-4-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/sthilden/advent_of_code [INFO] finished tweaking git repo https://github.com/sthilden/advent_of_code [INFO] tweaked toml for git repo https://github.com/sthilden/advent_of_code written to /workspace/builds/worker-4-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/sthilden/advent_of_code on toolchain nightly [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] crate git repo https://github.com/sthilden/advent_of_code already has a lockfile, it will not be regenerated [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded itertools v0.12.0 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+nightly" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] b0e3cd2369e072748774975ba04f2788870f8e91daad228471c9b261cf1c12cc [INFO] running `Command { std: "docker" "start" "-a" "b0e3cd2369e072748774975ba04f2788870f8e91daad228471c9b261cf1c12cc", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "b0e3cd2369e072748774975ba04f2788870f8e91daad228471c9b261cf1c12cc", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "b0e3cd2369e072748774975ba04f2788870f8e91daad228471c9b261cf1c12cc", kill_on_drop: false }` [INFO] [stdout] b0e3cd2369e072748774975ba04f2788870f8e91daad228471c9b261cf1c12cc [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+nightly" "clippy" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 6fa8a2426cf12627eaf7565d2f7689e0eff3de0e43299d2844cf129c227a77e9 [INFO] running `Command { std: "docker" "start" "-a" "6fa8a2426cf12627eaf7565d2f7689e0eff3de0e43299d2844cf129c227a77e9", kill_on_drop: false }` [INFO] [stderr] Compiling num-traits v0.2.17 [INFO] [stderr] Compiling num-integer v0.1.45 [INFO] [stderr] Compiling num-bigint v0.4.4 [INFO] [stderr] Compiling num-iter v0.1.43 [INFO] [stderr] Compiling num-rational v0.4.1 [INFO] [stderr] Checking either v1.9.0 [INFO] [stderr] Checking itertools v0.12.0 [INFO] [stderr] Checking num-complex v0.4.4 [INFO] [stderr] Checking num v0.4.1 [INFO] [stderr] Checking adevent_of_code v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unused import: `vec` [INFO] [stdout] --> src/year2023/day3.rs:1:50 [INFO] [stdout] | [INFO] [stdout] 1 | use std::{collections::BTreeMap, fs, path::Path, vec}; [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `vec` [INFO] [stdout] --> src/year2023/day3.rs:1:50 [INFO] [stdout] | [INFO] [stdout] 1 | use std::{collections::BTreeMap, fs, path::Path, vec}; [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary `>= y + 1` or `x - 1 >=` [INFO] [stdout] --> src/year2023/day5.rs:32:39 [INFO] [stdout] | [INFO] [stdout] 32 | if *source_start <= source && source <= source_start + length - 1 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: change it to: `source < source_start + length` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#int_plus_one [INFO] [stdout] = note: `#[warn(clippy::int_plus_one)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary `>= y + 1` or `x - 1 >=` [INFO] [stdout] --> src/year2023/day5.rs:32:39 [INFO] [stdout] | [INFO] [stdout] 32 | if *source_start <= source && source <= source_start + length - 1 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: change it to: `source < source_start + length` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#int_plus_one [INFO] [stdout] = note: `#[warn(clippy::int_plus_one)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `itertools::Itertools` [INFO] [stdout] --> src/year2023/day8.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use itertools::Itertools; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `num::integer::lcm` [INFO] [stdout] --> src/year2023/day8.rs:4:5 [INFO] [stdout] | [INFO] [stdout] 4 | use num::integer::lcm; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `itertools::Itertools` [INFO] [stdout] --> src/year2023/day8.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use itertools::Itertools; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `num::integer::lcm` [INFO] [stdout] --> src/year2023/day8.rs:4:5 [INFO] [stdout] | [INFO] [stdout] 4 | use num::integer::lcm; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `prev_pos` is never read [INFO] [stdout] --> src/year2023/day10.rs:251:28 [INFO] [stdout] | [INFO] [stdout] 251 | let mut prev_pos = pos; [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] = note: `#[warn(unused_assignments)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `prev_pos` is never read [INFO] [stdout] --> src/year2023/day10.rs:251:28 [INFO] [stdout] | [INFO] [stdout] 251 | let mut prev_pos = pos; [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] = note: `#[warn(unused_assignments)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/year2023/day8.rs:111:9 [INFO] [stdout] | [INFO] [stdout] 111 | let mut positions: Vec<&str> = map [INFO] [stdout] | ----^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_mut)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/year2023/day8.rs:111:9 [INFO] [stdout] | [INFO] [stdout] 111 | let mut positions: Vec<&str> = map [INFO] [stdout] | ----^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_mut)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day1.rs:3:8 [INFO] [stdout] | [INFO] [stdout] 3 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day1.rs:3:8 [INFO] [stdout] | [INFO] [stdout] 3 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day1.rs:22:8 [INFO] [stdout] | [INFO] [stdout] 22 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day1.rs:22:8 [INFO] [stdout] | [INFO] [stdout] 22 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Direction` is never used [INFO] [stdout] --> src/year2023/day10.rs:4:6 [INFO] [stdout] | [INFO] [stdout] 4 | enum Direction { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Direction` is never used [INFO] [stdout] --> src/year2023/day10.rs:4:6 [INFO] [stdout] | [INFO] [stdout] 4 | enum Direction { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `new_direction` is never used [INFO] [stdout] --> src/year2023/day10.rs:11:4 [INFO] [stdout] | [INFO] [stdout] 11 | fn new_direction(c: char, dir: Direction) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `new_direction` is never used [INFO] [stdout] --> src/year2023/day10.rs:11:4 [INFO] [stdout] | [INFO] [stdout] 11 | fn new_direction(c: char, dir: Direction) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `new_position` is never used [INFO] [stdout] --> src/year2023/day10.rs:39:4 [INFO] [stdout] | [INFO] [stdout] 39 | fn new_position( [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day10.rs:81:8 [INFO] [stdout] | [INFO] [stdout] 81 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Color` is never used [INFO] [stdout] --> src/year2023/day10.rs:150:6 [INFO] [stdout] | [INFO] [stdout] 150 | enum Color { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `set_color` is never used [INFO] [stdout] --> src/year2023/day10.rs:157:4 [INFO] [stdout] | [INFO] [stdout] 157 | fn set_color(map: &mut Vec>, i: usize, j: usize, color: Color) { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `get_left_right` is never used [INFO] [stdout] --> src/year2023/day10.rs:163:4 [INFO] [stdout] | [INFO] [stdout] 163 | fn get_left_right(map: &Vec>, i: usize, j: usize) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `update_color_map` is never used [INFO] [stdout] --> src/year2023/day10.rs:179:4 [INFO] [stdout] | [INFO] [stdout] 179 | fn update_color_map(color_map: &mut Vec>, dir: Direction, pos: (usize, usize)) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day10.rs:208:8 [INFO] [stdout] | [INFO] [stdout] 208 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `distance` is never used [INFO] [stdout] --> src/year2023/day11.rs:3:4 [INFO] [stdout] | [INFO] [stdout] 3 | fn distance(g1: (usize, usize), g2: (usize, usize)) -> usize { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `solve` is never used [INFO] [stdout] --> src/year2023/day11.rs:8:4 [INFO] [stdout] | [INFO] [stdout] 8 | fn solve(expansion_factor: usize) -> usize { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day11.rs:85:8 [INFO] [stdout] | [INFO] [stdout] 85 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day11.rs:91:8 [INFO] [stdout] | [INFO] [stdout] 91 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Spring` is never used [INFO] [stdout] --> src/year2023/day12.rs:4:6 [INFO] [stdout] | [INFO] [stdout] 4 | enum Spring { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `is_valid` is never used [INFO] [stdout] --> src/year2023/day12.rs:10:4 [INFO] [stdout] | [INFO] [stdout] 10 | fn is_valid(list: &Vec, groups: &Vec) -> bool { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `solve` is never used [INFO] [stdout] --> src/year2023/day12.rs:40:4 [INFO] [stdout] | [INFO] [stdout] 40 | fn solve(list: &Vec, groups: &Vec) -> usize { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day12.rs:97:8 [INFO] [stdout] | [INFO] [stdout] 97 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day12.rs:129:8 [INFO] [stdout] | [INFO] [stdout] 129 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Item` is never used [INFO] [stdout] --> src/year2023/day13.rs:4:6 [INFO] [stdout] | [INFO] [stdout] 4 | enum Item { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Pattern` is never constructed [INFO] [stdout] --> src/year2023/day13.rs:10:8 [INFO] [stdout] | [INFO] [stdout] 10 | struct Pattern { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new` is never used [INFO] [stdout] --> src/year2023/day13.rs:16:12 [INFO] [stdout] | [INFO] [stdout] 15 | impl Pattern { [INFO] [stdout] | ------------ associated function in this implementation [INFO] [stdout] 16 | pub fn new() -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_symmtery_one_dimension` is never used [INFO] [stdout] --> src/year2023/day13.rs:24:4 [INFO] [stdout] | [INFO] [stdout] 24 | fn find_symmtery_one_dimension(items: &Vec>, avoid: Option) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_symmetry` is never used [INFO] [stdout] --> src/year2023/day13.rs:51:4 [INFO] [stdout] | [INFO] [stdout] 51 | fn find_symmetry(pattern: &Pattern) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `swapItem` is never used [INFO] [stdout] --> src/year2023/day13.rs:63:4 [INFO] [stdout] | [INFO] [stdout] 63 | fn swapItem(item: Item) -> Item { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_smudged_symmetry` is never used [INFO] [stdout] --> src/year2023/day13.rs:70:4 [INFO] [stdout] | [INFO] [stdout] 70 | fn find_smudged_symmetry(pattern: &Pattern) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `read_input` is never used [INFO] [stdout] --> src/year2023/day13.rs:106:4 [INFO] [stdout] | [INFO] [stdout] 106 | fn read_input() -> Vec { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day13.rs:162:8 [INFO] [stdout] | [INFO] [stdout] 162 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day13.rs:171:8 [INFO] [stdout] | [INFO] [stdout] 171 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Item` is never used [INFO] [stdout] --> src/year2023/day14.rs:7:6 [INFO] [stdout] | [INFO] [stdout] 7 | enum Item { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Platform` is never constructed [INFO] [stdout] --> src/year2023/day14.rs:14:8 [INFO] [stdout] | [INFO] [stdout] 14 | struct Platform { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new` is never used [INFO] [stdout] --> src/year2023/day14.rs:19:12 [INFO] [stdout] | [INFO] [stdout] 18 | impl Platform { [INFO] [stdout] | ------------- associated function in this implementation [INFO] [stdout] 19 | pub fn new() -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `read_input` is never used [INFO] [stdout] --> src/year2023/day14.rs:24:4 [INFO] [stdout] | [INFO] [stdout] 24 | fn read_input() -> Platform { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day14.rs:51:8 [INFO] [stdout] | [INFO] [stdout] 51 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `print_platform` is never used [INFO] [stdout] --> src/year2023/day14.rs:95:4 [INFO] [stdout] | [INFO] [stdout] 95 | fn print_platform(platform: &Platform) { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `do_cycle` is never used [INFO] [stdout] --> src/year2023/day14.rs:112:4 [INFO] [stdout] | [INFO] [stdout] 112 | fn do_cycle(platform: &mut Platform) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `calculate_hash` is never used [INFO] [stdout] --> src/year2023/day14.rs:182:4 [INFO] [stdout] | [INFO] [stdout] 182 | fn calculate_hash(t: &T) -> u64 { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day14.rs:188:8 [INFO] [stdout] | [INFO] [stdout] 188 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day16.rs:183:8 [INFO] [stdout] | [INFO] [stdout] 183 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day2.rs:3:8 [INFO] [stdout] | [INFO] [stdout] 3 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day2.rs:39:8 [INFO] [stdout] | [INFO] [stdout] 39 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `is_symbol` is never used [INFO] [stdout] --> src/year2023/day3.rs:3:4 [INFO] [stdout] | [INFO] [stdout] 3 | fn is_symbol(schematics: &Vec>, row_inx: usize, col_inx: usize) -> bool { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `is_part_number` is never used [INFO] [stdout] --> src/year2023/day3.rs:8:4 [INFO] [stdout] | [INFO] [stdout] 8 | fn is_part_number( [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `get_part_number` is never used [INFO] [stdout] --> src/year2023/day3.rs:50:4 [INFO] [stdout] | [INFO] [stdout] 50 | fn get_part_number( [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day3.rs:69:8 [INFO] [stdout] | [INFO] [stdout] 69 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `check_for_gear` is never used [INFO] [stdout] --> src/year2023/day3.rs:116:4 [INFO] [stdout] | [INFO] [stdout] 116 | fn check_for_gear( [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `check_for_gears` is never used [INFO] [stdout] --> src/year2023/day3.rs:135:4 [INFO] [stdout] | [INFO] [stdout] 135 | fn check_for_gears( [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day3.rs:179:8 [INFO] [stdout] | [INFO] [stdout] 179 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day4.rs:3:8 [INFO] [stdout] | [INFO] [stdout] 3 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day4.rs:34:8 [INFO] [stdout] | [INFO] [stdout] 34 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `MapType` is never used [INFO] [stdout] --> src/year2023/day5.rs:5:6 [INFO] [stdout] | [INFO] [stdout] 5 | enum MapType { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `name_to_map_type` is never used [INFO] [stdout] --> src/year2023/day5.rs:15:4 [INFO] [stdout] | [INFO] [stdout] 15 | fn name_to_map_type(name: &str) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `map` is never used [INFO] [stdout] --> src/year2023/day5.rs:28:4 [INFO] [stdout] | [INFO] [stdout] 28 | fn map(source: u64, map: &Vec<(u64, u64, u64)>) -> u64 { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `map2` is never used [INFO] [stdout] --> src/year2023/day5.rs:39:4 [INFO] [stdout] | [INFO] [stdout] 39 | fn map2(sources: &Vec<(u64, u64)>, map: &Vec<(u64, u64, u64)>) -> Vec<(u64, u64)> { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day5.rs:96:8 [INFO] [stdout] | [INFO] [stdout] 96 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day5.rs:152:8 [INFO] [stdout] | [INFO] [stdout] 152 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `compute` is never used [INFO] [stdout] --> src/year2023/day6.rs:3:4 [INFO] [stdout] | [INFO] [stdout] 3 | fn compute(time: &Vec, dist: &Vec) -> u64 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day6.rs:28:8 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day6.rs:60:8 [INFO] [stdout] | [INFO] [stdout] 60 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Value` is never used [INFO] [stdout] --> src/year2023/day7.rs:4:6 [INFO] [stdout] | [INFO] [stdout] 4 | enum Value { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `from_char` and `joker_value` are never used [INFO] [stdout] --> src/year2023/day7.rs:21:8 [INFO] [stdout] | [INFO] [stdout] 20 | impl Value { [INFO] [stdout] | ---------- associated items in this implementation [INFO] [stdout] 21 | fn from_char(c: char) -> Option { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 40 | fn joker_value(&self) -> u8 { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `new_position` is never used [INFO] [stdout] --> src/year2023/day10.rs:39:4 [INFO] [stdout] | [INFO] [stdout] 39 | fn new_position( [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day10.rs:81:8 [INFO] [stdout] | [INFO] [stdout] 81 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Color` is never used [INFO] [stdout] --> src/year2023/day10.rs:150:6 [INFO] [stdout] | [INFO] [stdout] 150 | enum Color { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `set_color` is never used [INFO] [stdout] --> src/year2023/day10.rs:157:4 [INFO] [stdout] | [INFO] [stdout] 157 | fn set_color(map: &mut Vec>, i: usize, j: usize, color: Color) { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `get_left_right` is never used [INFO] [stdout] --> src/year2023/day10.rs:163:4 [INFO] [stdout] | [INFO] [stdout] 163 | fn get_left_right(map: &Vec>, i: usize, j: usize) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `update_color_map` is never used [INFO] [stdout] --> src/year2023/day10.rs:179:4 [INFO] [stdout] | [INFO] [stdout] 179 | fn update_color_map(color_map: &mut Vec>, dir: Direction, pos: (usize, usize)) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day10.rs:208:8 [INFO] [stdout] | [INFO] [stdout] 208 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `distance` is never used [INFO] [stdout] --> src/year2023/day11.rs:3:4 [INFO] [stdout] | [INFO] [stdout] 3 | fn distance(g1: (usize, usize), g2: (usize, usize)) -> usize { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `solve` is never used [INFO] [stdout] --> src/year2023/day11.rs:8:4 [INFO] [stdout] | [INFO] [stdout] 8 | fn solve(expansion_factor: usize) -> usize { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day11.rs:85:8 [INFO] [stdout] | [INFO] [stdout] 85 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day11.rs:91:8 [INFO] [stdout] | [INFO] [stdout] 91 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Spring` is never used [INFO] [stdout] --> src/year2023/day12.rs:4:6 [INFO] [stdout] | [INFO] [stdout] 4 | enum Spring { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `is_valid` is never used [INFO] [stdout] --> src/year2023/day12.rs:10:4 [INFO] [stdout] | [INFO] [stdout] 10 | fn is_valid(list: &Vec, groups: &Vec) -> bool { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `solve` is never used [INFO] [stdout] --> src/year2023/day12.rs:40:4 [INFO] [stdout] | [INFO] [stdout] 40 | fn solve(list: &Vec, groups: &Vec) -> usize { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day12.rs:97:8 [INFO] [stdout] | [INFO] [stdout] 97 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day12.rs:129:8 [INFO] [stdout] | [INFO] [stdout] 129 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Item` is never used [INFO] [stdout] --> src/year2023/day13.rs:4:6 [INFO] [stdout] | [INFO] [stdout] 4 | enum Item { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Pattern` is never constructed [INFO] [stdout] --> src/year2023/day13.rs:10:8 [INFO] [stdout] | [INFO] [stdout] 10 | struct Pattern { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new` is never used [INFO] [stdout] --> src/year2023/day13.rs:16:12 [INFO] [stdout] | [INFO] [stdout] 15 | impl Pattern { [INFO] [stdout] | ------------ associated function in this implementation [INFO] [stdout] 16 | pub fn new() -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_symmtery_one_dimension` is never used [INFO] [stdout] --> src/year2023/day13.rs:24:4 [INFO] [stdout] | [INFO] [stdout] 24 | fn find_symmtery_one_dimension(items: &Vec>, avoid: Option) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_symmetry` is never used [INFO] [stdout] --> src/year2023/day13.rs:51:4 [INFO] [stdout] | [INFO] [stdout] 51 | fn find_symmetry(pattern: &Pattern) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `swapItem` is never used [INFO] [stdout] --> src/year2023/day13.rs:63:4 [INFO] [stdout] | [INFO] [stdout] 63 | fn swapItem(item: Item) -> Item { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_smudged_symmetry` is never used [INFO] [stdout] --> src/year2023/day13.rs:70:4 [INFO] [stdout] | [INFO] [stdout] 70 | fn find_smudged_symmetry(pattern: &Pattern) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `read_input` is never used [INFO] [stdout] --> src/year2023/day13.rs:106:4 [INFO] [stdout] | [INFO] [stdout] 106 | fn read_input() -> Vec { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day13.rs:162:8 [INFO] [stdout] | [INFO] [stdout] 162 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day13.rs:171:8 [INFO] [stdout] | [INFO] [stdout] 171 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Item` is never used [INFO] [stdout] --> src/year2023/day14.rs:7:6 [INFO] [stdout] | [INFO] [stdout] 7 | enum Item { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Platform` is never constructed [INFO] [stdout] --> src/year2023/day14.rs:14:8 [INFO] [stdout] | [INFO] [stdout] 14 | struct Platform { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new` is never used [INFO] [stdout] --> src/year2023/day14.rs:19:12 [INFO] [stdout] | [INFO] [stdout] 18 | impl Platform { [INFO] [stdout] | ------------- associated function in this implementation [INFO] [stdout] 19 | pub fn new() -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `read_input` is never used [INFO] [stdout] --> src/year2023/day14.rs:24:4 [INFO] [stdout] | [INFO] [stdout] 24 | fn read_input() -> Platform { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day14.rs:51:8 [INFO] [stdout] | [INFO] [stdout] 51 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `print_platform` is never used [INFO] [stdout] --> src/year2023/day14.rs:95:4 [INFO] [stdout] | [INFO] [stdout] 95 | fn print_platform(platform: &Platform) { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `do_cycle` is never used [INFO] [stdout] --> src/year2023/day14.rs:112:4 [INFO] [stdout] | [INFO] [stdout] 112 | fn do_cycle(platform: &mut Platform) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `calculate_hash` is never used [INFO] [stdout] --> src/year2023/day14.rs:182:4 [INFO] [stdout] | [INFO] [stdout] 182 | fn calculate_hash(t: &T) -> u64 { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day14.rs:188:8 [INFO] [stdout] | [INFO] [stdout] 188 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day16.rs:183:8 [INFO] [stdout] | [INFO] [stdout] 183 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day2.rs:3:8 [INFO] [stdout] | [INFO] [stdout] 3 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day2.rs:39:8 [INFO] [stdout] | [INFO] [stdout] 39 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `is_symbol` is never used [INFO] [stdout] --> src/year2023/day3.rs:3:4 [INFO] [stdout] | [INFO] [stdout] 3 | fn is_symbol(schematics: &Vec>, row_inx: usize, col_inx: usize) -> bool { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `is_part_number` is never used [INFO] [stdout] --> src/year2023/day3.rs:8:4 [INFO] [stdout] | [INFO] [stdout] 8 | fn is_part_number( [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `get_part_number` is never used [INFO] [stdout] --> src/year2023/day3.rs:50:4 [INFO] [stdout] | [INFO] [stdout] 50 | fn get_part_number( [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day3.rs:69:8 [INFO] [stdout] | [INFO] [stdout] 69 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `check_for_gear` is never used [INFO] [stdout] --> src/year2023/day3.rs:116:4 [INFO] [stdout] | [INFO] [stdout] 116 | fn check_for_gear( [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `check_for_gears` is never used [INFO] [stdout] --> src/year2023/day3.rs:135:4 [INFO] [stdout] | [INFO] [stdout] 135 | fn check_for_gears( [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day3.rs:179:8 [INFO] [stdout] | [INFO] [stdout] 179 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day4.rs:3:8 [INFO] [stdout] | [INFO] [stdout] 3 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day4.rs:34:8 [INFO] [stdout] | [INFO] [stdout] 34 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `MapType` is never used [INFO] [stdout] --> src/year2023/day5.rs:5:6 [INFO] [stdout] | [INFO] [stdout] 5 | enum MapType { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `name_to_map_type` is never used [INFO] [stdout] --> src/year2023/day5.rs:15:4 [INFO] [stdout] | [INFO] [stdout] 15 | fn name_to_map_type(name: &str) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `map` is never used [INFO] [stdout] --> src/year2023/day5.rs:28:4 [INFO] [stdout] | [INFO] [stdout] 28 | fn map(source: u64, map: &Vec<(u64, u64, u64)>) -> u64 { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `map2` is never used [INFO] [stdout] --> src/year2023/day5.rs:39:4 [INFO] [stdout] | [INFO] [stdout] 39 | fn map2(sources: &Vec<(u64, u64)>, map: &Vec<(u64, u64, u64)>) -> Vec<(u64, u64)> { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day5.rs:96:8 [INFO] [stdout] | [INFO] [stdout] 96 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day5.rs:152:8 [INFO] [stdout] | [INFO] [stdout] 152 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `compute` is never used [INFO] [stdout] --> src/year2023/day6.rs:3:4 [INFO] [stdout] | [INFO] [stdout] 3 | fn compute(time: &Vec, dist: &Vec) -> u64 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day6.rs:28:8 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day6.rs:60:8 [INFO] [stdout] | [INFO] [stdout] 60 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Value` is never used [INFO] [stdout] --> src/year2023/day7.rs:4:6 [INFO] [stdout] | [INFO] [stdout] 4 | enum Value { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `from_char` and `joker_value` are never used [INFO] [stdout] --> src/year2023/day7.rs:21:8 [INFO] [stdout] | [INFO] [stdout] 20 | impl Value { [INFO] [stdout] | ---------- associated items in this implementation [INFO] [stdout] 21 | fn from_char(c: char) -> Option { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 40 | fn joker_value(&self) -> u8 { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Type` is never used [INFO] [stdout] --> src/year2023/day7.rs:60:6 [INFO] [stdout] | [INFO] [stdout] 60 | enum Type { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Type` is never used [INFO] [stdout] --> src/year2023/day7.rs:60:6 [INFO] [stdout] | [INFO] [stdout] 60 | enum Type { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated functions `from_cards` and `from_cards_with_joker` are never used [INFO] [stdout] --> src/year2023/day7.rs:71:8 [INFO] [stdout] | [INFO] [stdout] 70 | impl Type { [INFO] [stdout] | --------- associated functions in this implementation [INFO] [stdout] 71 | fn from_cards(cards: &[Value; 5]) -> Type { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 96 | fn from_cards_with_joker(cards: &[Value; 5]) -> Type { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Hand` is never constructed [INFO] [stdout] --> src/year2023/day7.rs:130:8 [INFO] [stdout] | [INFO] [stdout] 130 | struct Hand { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated functions `get_cards`, `from_str`, and `from_str_with_joker` are never used [INFO] [stdout] --> src/year2023/day7.rs:136:8 [INFO] [stdout] | [INFO] [stdout] 135 | impl Hand { [INFO] [stdout] | --------- associated functions in this implementation [INFO] [stdout] 136 | fn get_cards(s: &str) -> Option<[Value; 5]> { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 149 | fn from_str(s: &str) -> Option { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 157 | fn from_str_with_joker(s: &str) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day7.rs:166:8 [INFO] [stdout] | [INFO] [stdout] 166 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day7.rs:197:8 [INFO] [stdout] | [INFO] [stdout] 197 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `rem_first_and_last` is never used [INFO] [stdout] --> src/year2023/day8.rs:6:4 [INFO] [stdout] | [INFO] [stdout] 6 | fn rem_first_and_last(value: &str) -> &str { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Direction` is never used [INFO] [stdout] --> src/year2023/day8.rs:14:6 [INFO] [stdout] | [INFO] [stdout] 14 | enum Direction { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day8.rs:19:8 [INFO] [stdout] | [INFO] [stdout] 19 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day8.rs:74:8 [INFO] [stdout] | [INFO] [stdout] 74 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `solve` is never used [INFO] [stdout] --> src/year2023/day9.rs:3:4 [INFO] [stdout] | [INFO] [stdout] 3 | fn solve(contents: &str, reverse: bool) -> i64 { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day9.rs:45:8 [INFO] [stdout] | [INFO] [stdout] 45 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day9.rs:56:8 [INFO] [stdout] | [INFO] [stdout] 56 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated functions `from_cards` and `from_cards_with_joker` are never used [INFO] [stdout] --> src/year2023/day7.rs:71:8 [INFO] [stdout] | [INFO] [stdout] 70 | impl Type { [INFO] [stdout] | --------- associated functions in this implementation [INFO] [stdout] 71 | fn from_cards(cards: &[Value; 5]) -> Type { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 96 | fn from_cards_with_joker(cards: &[Value; 5]) -> Type { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Hand` is never constructed [INFO] [stdout] --> src/year2023/day7.rs:130:8 [INFO] [stdout] | [INFO] [stdout] 130 | struct Hand { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated functions `get_cards`, `from_str`, and `from_str_with_joker` are never used [INFO] [stdout] --> src/year2023/day7.rs:136:8 [INFO] [stdout] | [INFO] [stdout] 135 | impl Hand { [INFO] [stdout] | --------- associated functions in this implementation [INFO] [stdout] 136 | fn get_cards(s: &str) -> Option<[Value; 5]> { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 149 | fn from_str(s: &str) -> Option { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 157 | fn from_str_with_joker(s: &str) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day7.rs:166:8 [INFO] [stdout] | [INFO] [stdout] 166 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day7.rs:197:8 [INFO] [stdout] | [INFO] [stdout] 197 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `rem_first_and_last` is never used [INFO] [stdout] --> src/year2023/day8.rs:6:4 [INFO] [stdout] | [INFO] [stdout] 6 | fn rem_first_and_last(value: &str) -> &str { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Direction` is never used [INFO] [stdout] --> src/year2023/day8.rs:14:6 [INFO] [stdout] | [INFO] [stdout] 14 | enum Direction { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day8.rs:19:8 [INFO] [stdout] | [INFO] [stdout] 19 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day8.rs:74:8 [INFO] [stdout] | [INFO] [stdout] 74 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `solve` is never used [INFO] [stdout] --> src/year2023/day9.rs:3:4 [INFO] [stdout] | [INFO] [stdout] 3 | fn solve(contents: &str, reverse: bool) -> i64 { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem1` is never used [INFO] [stdout] --> src/year2023/day9.rs:45:8 [INFO] [stdout] | [INFO] [stdout] 45 | pub fn problem1() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `problem2` is never used [INFO] [stdout] --> src/year2023/day9.rs:56:8 [INFO] [stdout] | [INFO] [stdout] 56 | pub fn problem2() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day1.rs:10:5 [INFO] [stdout] | [INFO] [stdout] 10 | contents.lines().into_iter().for_each(|line| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] = note: `#[warn(clippy::useless_conversion)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day1.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | contents.lines().into_iter().for_each(|line| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day1.rs:10:5 [INFO] [stdout] | [INFO] [stdout] 10 | contents.lines().into_iter().for_each(|line| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] = note: `#[warn(clippy::useless_conversion)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day1.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | contents.lines().into_iter().for_each(|line| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day10.rs:42:10 [INFO] [stdout] | [INFO] [stdout] 42 | map: &Vec>, [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] = note: `#[warn(clippy::ptr_arg)]` on by default [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 42 - map: &Vec>, [INFO] [stdout] 42 + map: &[Vec], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day10.rs:42:10 [INFO] [stdout] | [INFO] [stdout] 42 | map: &Vec>, [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] = note: `#[warn(clippy::ptr_arg)]` on by default [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 42 - map: &Vec>, [INFO] [stdout] 42 + map: &[Vec], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&mut Vec` instead of `&mut [_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day10.rs:157:19 [INFO] [stdout] | [INFO] [stdout] 157 | fn set_color(map: &mut Vec>, i: usize, j: usize, color: Color) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 157 - fn set_color(map: &mut Vec>, i: usize, j: usize, color: Color) { [INFO] [stdout] 157 + fn set_color(map: &mut [Vec], i: usize, j: usize, color: Color) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&mut Vec` instead of `&mut [_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day10.rs:157:19 [INFO] [stdout] | [INFO] [stdout] 157 | fn set_color(map: &mut Vec>, i: usize, j: usize, color: Color) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 157 - fn set_color(map: &mut Vec>, i: usize, j: usize, color: Color) { [INFO] [stdout] 157 + fn set_color(map: &mut [Vec], i: usize, j: usize, color: Color) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day10.rs:163:24 [INFO] [stdout] | [INFO] [stdout] 163 | fn get_left_right(map: &Vec>, i: usize, j: usize) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 163 - fn get_left_right(map: &Vec>, i: usize, j: usize) -> Option { [INFO] [stdout] 163 + fn get_left_right(map: &[Vec], i: usize, j: usize) -> Option { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day10.rs:163:24 [INFO] [stdout] | [INFO] [stdout] 163 | fn get_left_right(map: &Vec>, i: usize, j: usize) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 163 - fn get_left_right(map: &Vec>, i: usize, j: usize) -> Option { [INFO] [stdout] 163 + fn get_left_right(map: &[Vec], i: usize, j: usize) -> Option { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `j` is only used to index `map` [INFO] [stdout] --> src/year2023/day11.rs:29:18 [INFO] [stdout] | [INFO] [stdout] 29 | for j in 0..map.len() { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] = note: `#[warn(clippy::needless_range_loop)]` on by default [INFO] [stdout] help: consider using an iterator [INFO] [stdout] | [INFO] [stdout] 29 - for j in 0..map.len() { [INFO] [stdout] 29 + for in &map { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `j` is only used to index `map` [INFO] [stdout] --> src/year2023/day11.rs:29:18 [INFO] [stdout] | [INFO] [stdout] 29 | for j in 0..map.len() { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] = note: `#[warn(clippy::needless_range_loop)]` on by default [INFO] [stdout] help: consider using an iterator [INFO] [stdout] | [INFO] [stdout] 29 - for j in 0..map.len() { [INFO] [stdout] 29 + for in &map { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `i` is only used to index `map` [INFO] [stdout] --> src/year2023/day11.rs:46:18 [INFO] [stdout] | [INFO] [stdout] 46 | for i in 0..map.len() { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] help: consider using an iterator [INFO] [stdout] | [INFO] [stdout] 46 - for i in 0..map.len() { [INFO] [stdout] 46 + for in &map { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `j` is used to index `map` [INFO] [stdout] --> src/year2023/day11.rs:61:18 [INFO] [stdout] | [INFO] [stdout] 61 | for j in 0..map.len() { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] help: consider using an iterator and enumerate() [INFO] [stdout] | [INFO] [stdout] 61 - for j in 0..map.len() { [INFO] [stdout] 61 + for (j, ) in map.iter().enumerate() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `i` is only used to index `map` [INFO] [stdout] --> src/year2023/day11.rs:46:18 [INFO] [stdout] | [INFO] [stdout] 46 | for i in 0..map.len() { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] help: consider using an iterator [INFO] [stdout] | [INFO] [stdout] 46 - for i in 0..map.len() { [INFO] [stdout] 46 + for in &map { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `j` is used to index `map` [INFO] [stdout] --> src/year2023/day11.rs:61:18 [INFO] [stdout] | [INFO] [stdout] 61 | for j in 0..map.len() { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] help: consider using an iterator and enumerate() [INFO] [stdout] | [INFO] [stdout] 61 - for j in 0..map.len() { [INFO] [stdout] 61 + for (j, ) in map.iter().enumerate() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day12.rs:10:19 [INFO] [stdout] | [INFO] [stdout] 10 | fn is_valid(list: &Vec, groups: &Vec) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 10 - fn is_valid(list: &Vec, groups: &Vec) -> bool { [INFO] [stdout] 10 + fn is_valid(list: &[Spring], groups: &Vec) -> bool { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day12.rs:10:19 [INFO] [stdout] | [INFO] [stdout] 10 | fn is_valid(list: &Vec, groups: &Vec) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 10 - fn is_valid(list: &Vec, groups: &Vec) -> bool { [INFO] [stdout] 10 + fn is_valid(list: &[Spring], groups: &Vec) -> bool { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day12.rs:58:21 [INFO] [stdout] | [INFO] [stdout] 58 | if is_valid(&list, groups) { [INFO] [stdout] | ^^^^^ help: change this to: `list` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day12.rs:58:21 [INFO] [stdout] | [INFO] [stdout] 58 | if is_valid(&list, groups) { [INFO] [stdout] | ^^^^^ help: change this to: `list` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day12.rs:71:45 [INFO] [stdout] | [INFO] [stdout] 71 | solutions += solve(&list_clone, &groups); [INFO] [stdout] | ^^^^^^^ help: change this to: `groups` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day12.rs:73:45 [INFO] [stdout] | [INFO] [stdout] 73 | solutions += solve(&list_clone, &groups); [INFO] [stdout] | ^^^^^^^ help: change this to: `groups` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Chars<'_>` [INFO] [stdout] --> src/year2023/day12.rs:106:20 [INFO] [stdout] | [INFO] [stdout] 106 | let list = list_str [INFO] [stdout] | ____________________^ [INFO] [stdout] 107 | | .chars() [INFO] [stdout] 108 | | .into_iter() [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 106 ~ let list = list_str [INFO] [stdout] 107 + .chars() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day12.rs:71:45 [INFO] [stdout] | [INFO] [stdout] 71 | solutions += solve(&list_clone, &groups); [INFO] [stdout] | ^^^^^^^ help: change this to: `groups` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day12.rs:73:45 [INFO] [stdout] | [INFO] [stdout] 73 | solutions += solve(&list_clone, &groups); [INFO] [stdout] | ^^^^^^^ help: change this to: `groups` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Chars<'_>` [INFO] [stdout] --> src/year2023/day12.rs:106:20 [INFO] [stdout] | [INFO] [stdout] 106 | let list = list_str [INFO] [stdout] | ____________________^ [INFO] [stdout] 107 | | .chars() [INFO] [stdout] 108 | | .into_iter() [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 106 ~ let list = list_str [INFO] [stdout] 107 + .chars() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Split<'_, char>` [INFO] [stdout] --> src/year2023/day12.rs:116:22 [INFO] [stdout] | [INFO] [stdout] 116 | let groups = groups_str [INFO] [stdout] | ______________________^ [INFO] [stdout] 117 | | .split(',') [INFO] [stdout] 118 | | .into_iter() [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 116 ~ let groups = groups_str [INFO] [stdout] 117 + .split(',') [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Split<'_, char>` [INFO] [stdout] --> src/year2023/day12.rs:116:22 [INFO] [stdout] | [INFO] [stdout] 116 | let groups = groups_str [INFO] [stdout] | ______________________^ [INFO] [stdout] 117 | | .split(',') [INFO] [stdout] 118 | | .into_iter() [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 116 ~ let groups = groups_str [INFO] [stdout] 117 + .split(',') [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Chars<'_>` [INFO] [stdout] --> src/year2023/day12.rs:138:20 [INFO] [stdout] | [INFO] [stdout] 138 | let list = list_str [INFO] [stdout] | ____________________^ [INFO] [stdout] 139 | | .chars() [INFO] [stdout] 140 | | .into_iter() [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 138 ~ let list = list_str [INFO] [stdout] 139 + .chars() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Chars<'_>` [INFO] [stdout] --> src/year2023/day12.rs:138:20 [INFO] [stdout] | [INFO] [stdout] 138 | let list = list_str [INFO] [stdout] | ____________________^ [INFO] [stdout] 139 | | .chars() [INFO] [stdout] 140 | | .into_iter() [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 138 ~ let list = list_str [INFO] [stdout] 139 + .chars() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Split<'_, char>` [INFO] [stdout] --> src/year2023/day12.rs:148:22 [INFO] [stdout] | [INFO] [stdout] 148 | let groups = groups_str [INFO] [stdout] | ______________________^ [INFO] [stdout] 149 | | .split(',') [INFO] [stdout] 150 | | .into_iter() [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 148 ~ let groups = groups_str [INFO] [stdout] 149 + .split(',') [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Split<'_, char>` [INFO] [stdout] --> src/year2023/day12.rs:148:22 [INFO] [stdout] | [INFO] [stdout] 148 | let groups = groups_str [INFO] [stdout] | ______________________^ [INFO] [stdout] 149 | | .split(',') [INFO] [stdout] 150 | | .into_iter() [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 148 ~ let groups = groups_str [INFO] [stdout] 149 + .split(',') [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day13.rs:24:39 [INFO] [stdout] | [INFO] [stdout] 24 | fn find_symmtery_one_dimension(items: &Vec>, avoid: Option) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 24 - fn find_symmtery_one_dimension(items: &Vec>, avoid: Option) -> usize { [INFO] [stdout] 24 + fn find_symmtery_one_dimension(items: &[Vec], avoid: Option) -> usize { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day13.rs:24:39 [INFO] [stdout] | [INFO] [stdout] 24 | fn find_symmtery_one_dimension(items: &Vec>, avoid: Option) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 24 - fn find_symmtery_one_dimension(items: &Vec>, avoid: Option) -> usize { [INFO] [stdout] 24 + fn find_symmtery_one_dimension(items: &[Vec], avoid: Option) -> usize { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Chars<'_>` [INFO] [stdout] --> src/year2023/day13.rs:125:21 [INFO] [stdout] | [INFO] [stdout] 125 | / line.chars() [INFO] [stdout] 126 | | .into_iter() [INFO] [stdout] | |____________________________________^ help: consider removing `.into_iter()`: `line.chars()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Chars<'_>` [INFO] [stdout] --> src/year2023/day13.rs:125:21 [INFO] [stdout] | [INFO] [stdout] 125 | / line.chars() [INFO] [stdout] 126 | | .into_iter() [INFO] [stdout] | |____________________________________^ help: consider removing `.into_iter()`: `line.chars()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> src/year2023/day13.rs:166:42 [INFO] [stdout] | [INFO] [stdout] 166 | let sum: usize = patterns.iter().map(|p| find_symmetry(p)).sum(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `find_symmetry` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] = note: `#[warn(clippy::redundant_closure)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> src/year2023/day13.rs:166:42 [INFO] [stdout] | [INFO] [stdout] 166 | let sum: usize = patterns.iter().map(|p| find_symmetry(p)).sum(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `find_symmetry` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] = note: `#[warn(clippy::redundant_closure)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> src/year2023/day13.rs:175:42 [INFO] [stdout] | [INFO] [stdout] 175 | let sum: usize = patterns.iter().map(|p| find_smudged_symmetry(p)).sum(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `find_smudged_symmetry` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> src/year2023/day13.rs:175:42 [INFO] [stdout] | [INFO] [stdout] 175 | let sum: usize = patterns.iter().map(|p| find_smudged_symmetry(p)).sum(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `find_smudged_symmetry` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Chars<'_>` [INFO] [stdout] --> src/year2023/day14.rs:36:13 [INFO] [stdout] | [INFO] [stdout] 36 | / line.chars() [INFO] [stdout] 37 | | .into_iter() [INFO] [stdout] | |____________________________^ help: consider removing `.into_iter()`: `line.chars()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Chars<'_>` [INFO] [stdout] --> src/year2023/day14.rs:36:13 [INFO] [stdout] | [INFO] [stdout] 36 | / line.chars() [INFO] [stdout] 37 | | .into_iter() [INFO] [stdout] | |____________________________^ help: consider removing `.into_iter()`: `line.chars()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: empty string literal in `println!` [INFO] [stdout] --> src/year2023/day14.rs:107:9 [INFO] [stdout] | [INFO] [stdout] 107 | println!(""); [INFO] [stdout] | ^^^^^^^^^--^ [INFO] [stdout] | | [INFO] [stdout] | help: remove the empty string [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#println_empty_string [INFO] [stdout] = note: `#[warn(clippy::println_empty_string)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: empty string literal in `println!` [INFO] [stdout] --> src/year2023/day14.rs:107:9 [INFO] [stdout] | [INFO] [stdout] 107 | println!(""); [INFO] [stdout] | ^^^^^^^^^--^ [INFO] [stdout] | | [INFO] [stdout] | help: remove the empty string [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#println_empty_string [INFO] [stdout] = note: `#[warn(clippy::println_empty_string)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: empty string literal in `println!` [INFO] [stdout] --> src/year2023/day14.rs:109:5 [INFO] [stdout] | [INFO] [stdout] 109 | println!(""); [INFO] [stdout] | ^^^^^^^^^--^ [INFO] [stdout] | | [INFO] [stdout] | help: remove the empty string [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#println_empty_string [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: empty string literal in `println!` [INFO] [stdout] --> src/year2023/day14.rs:109:5 [INFO] [stdout] | [INFO] [stdout] 109 | println!(""); [INFO] [stdout] | ^^^^^^^^^--^ [INFO] [stdout] | | [INFO] [stdout] | help: remove the empty string [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#println_empty_string [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day16.rs:57:34 [INFO] [stdout] | [INFO] [stdout] 57 | fn get_energized_tile_count(map: &Vec>, start_ray: Ray) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 57 - fn get_energized_tile_count(map: &Vec>, start_ray: Ray) -> usize { [INFO] [stdout] 57 + fn get_energized_tile_count(map: &[Vec], start_ray: Ray) -> usize { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day16.rs:57:34 [INFO] [stdout] | [INFO] [stdout] 57 | fn get_energized_tile_count(map: &Vec>, start_ray: Ray) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 57 - fn get_energized_tile_count(map: &Vec>, start_ray: Ray) -> usize { [INFO] [stdout] 57 + fn get_energized_tile_count(map: &[Vec], start_ray: Ray) -> usize { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day2.rs:14:5 [INFO] [stdout] | [INFO] [stdout] 14 | contents.lines().into_iter().for_each(|line| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day2.rs:14:5 [INFO] [stdout] | [INFO] [stdout] 14 | contents.lines().into_iter().for_each(|line| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day2.rs:47:5 [INFO] [stdout] | [INFO] [stdout] 47 | contents.lines().into_iter().for_each(|line| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day2.rs:47:5 [INFO] [stdout] | [INFO] [stdout] 47 | contents.lines().into_iter().for_each(|line| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Split<'_, char>` [INFO] [stdout] --> src/year2023/day2.rs:51:9 [INFO] [stdout] | [INFO] [stdout] 51 | sets.split(';').into_iter().for_each(|set| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `sets.split(';')` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Split<'_, char>` [INFO] [stdout] --> src/year2023/day2.rs:51:9 [INFO] [stdout] | [INFO] [stdout] 51 | sets.split(';').into_iter().for_each(|set| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `sets.split(';')` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Split<'_, &str>` [INFO] [stdout] --> src/year2023/day2.rs:52:13 [INFO] [stdout] | [INFO] [stdout] 52 | set.split(",").into_iter().for_each(|s| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `set.split(",")` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Split<'_, &str>` [INFO] [stdout] --> src/year2023/day2.rs:52:13 [INFO] [stdout] | [INFO] [stdout] 52 | set.split(",").into_iter().for_each(|s| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `set.split(",")` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/year2023/day3.rs:5:5 [INFO] [stdout] | [INFO] [stdout] 5 | return !c.is_alphanumeric() && c != '.'; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] = note: `#[warn(clippy::needless_return)]` on by default [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 5 - return !c.is_alphanumeric() && c != '.'; [INFO] [stdout] 5 + !c.is_alphanumeric() && c != '.' [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day3.rs:3:26 [INFO] [stdout] | [INFO] [stdout] 3 | fn is_symbol(schematics: &Vec>, row_inx: usize, col_inx: usize) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 3 - fn is_symbol(schematics: &Vec>, row_inx: usize, col_inx: usize) -> bool { [INFO] [stdout] 3 + fn is_symbol(schematics: &[Vec], row_inx: usize, col_inx: usize) -> bool { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/year2023/day3.rs:17:13 [INFO] [stdout] | [INFO] [stdout] 17 | / if 0 <= col_inx && (col_inx as usize) < schematics[row_inx - 1].len() { [INFO] [stdout] 18 | | if is_symbol(&schematics, row_inx - 1, col_inx as usize) { [INFO] [stdout] 19 | | return true; [INFO] [stdout] 20 | | } [INFO] [stdout] 21 | | } [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] = note: `#[warn(clippy::collapsible_if)]` on by default [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 17 ~ if 0 <= col_inx && (col_inx as usize) < schematics[row_inx - 1].len() [INFO] [stdout] 18 ~ && is_symbol(&schematics, row_inx - 1, col_inx as usize) { [INFO] [stdout] 19 | return true; [INFO] [stdout] 20 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:18:30 [INFO] [stdout] | [INFO] [stdout] 18 | if is_symbol(&schematics, row_inx - 1, col_inx as usize) { [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/year2023/day3.rs:27:13 [INFO] [stdout] | [INFO] [stdout] 27 | / if 0 <= col_inx && (col_inx as usize) < schematics[row_inx + 1].len() { [INFO] [stdout] 28 | | if is_symbol(&schematics, row_inx + 1, col_inx as usize) { [INFO] [stdout] 29 | | return true; [INFO] [stdout] 30 | | } [INFO] [stdout] 31 | | } [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 27 ~ if 0 <= col_inx && (col_inx as usize) < schematics[row_inx + 1].len() [INFO] [stdout] 28 ~ && is_symbol(&schematics, row_inx + 1, col_inx as usize) { [INFO] [stdout] 29 | return true; [INFO] [stdout] 30 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:28:30 [INFO] [stdout] | [INFO] [stdout] 28 | if is_symbol(&schematics, row_inx + 1, col_inx as usize) { [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/year2023/day3.rs:35:5 [INFO] [stdout] | [INFO] [stdout] 35 | / if col_inx_first > 0 { [INFO] [stdout] 36 | | if is_symbol(&schematics, row_inx, col_inx_first - 1) { [INFO] [stdout] 37 | | return true; [INFO] [stdout] 38 | | } [INFO] [stdout] 39 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 35 ~ if col_inx_first > 0 [INFO] [stdout] 36 ~ && is_symbol(&schematics, row_inx, col_inx_first - 1) { [INFO] [stdout] 37 | return true; [INFO] [stdout] 38 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:36:22 [INFO] [stdout] | [INFO] [stdout] 36 | if is_symbol(&schematics, row_inx, col_inx_first - 1) { [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/year2023/day3.rs:5:5 [INFO] [stdout] | [INFO] [stdout] 5 | return !c.is_alphanumeric() && c != '.'; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] = note: `#[warn(clippy::needless_return)]` on by default [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 5 - return !c.is_alphanumeric() && c != '.'; [INFO] [stdout] 5 + !c.is_alphanumeric() && c != '.' [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day3.rs:3:26 [INFO] [stdout] | [INFO] [stdout] 3 | fn is_symbol(schematics: &Vec>, row_inx: usize, col_inx: usize) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 3 - fn is_symbol(schematics: &Vec>, row_inx: usize, col_inx: usize) -> bool { [INFO] [stdout] 3 + fn is_symbol(schematics: &[Vec], row_inx: usize, col_inx: usize) -> bool { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/year2023/day3.rs:17:13 [INFO] [stdout] | [INFO] [stdout] 17 | / if 0 <= col_inx && (col_inx as usize) < schematics[row_inx - 1].len() { [INFO] [stdout] 18 | | if is_symbol(&schematics, row_inx - 1, col_inx as usize) { [INFO] [stdout] 19 | | return true; [INFO] [stdout] 20 | | } [INFO] [stdout] 21 | | } [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] = note: `#[warn(clippy::collapsible_if)]` on by default [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 17 ~ if 0 <= col_inx && (col_inx as usize) < schematics[row_inx - 1].len() [INFO] [stdout] 18 ~ && is_symbol(&schematics, row_inx - 1, col_inx as usize) { [INFO] [stdout] 19 | return true; [INFO] [stdout] 20 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:18:30 [INFO] [stdout] | [INFO] [stdout] 18 | if is_symbol(&schematics, row_inx - 1, col_inx as usize) { [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/year2023/day3.rs:27:13 [INFO] [stdout] | [INFO] [stdout] 27 | / if 0 <= col_inx && (col_inx as usize) < schematics[row_inx + 1].len() { [INFO] [stdout] 28 | | if is_symbol(&schematics, row_inx + 1, col_inx as usize) { [INFO] [stdout] 29 | | return true; [INFO] [stdout] 30 | | } [INFO] [stdout] 31 | | } [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 27 ~ if 0 <= col_inx && (col_inx as usize) < schematics[row_inx + 1].len() [INFO] [stdout] 28 ~ && is_symbol(&schematics, row_inx + 1, col_inx as usize) { [INFO] [stdout] 29 | return true; [INFO] [stdout] 30 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:28:30 [INFO] [stdout] | [INFO] [stdout] 28 | if is_symbol(&schematics, row_inx + 1, col_inx as usize) { [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/year2023/day3.rs:35:5 [INFO] [stdout] | [INFO] [stdout] 35 | / if col_inx_first > 0 { [INFO] [stdout] 36 | | if is_symbol(&schematics, row_inx, col_inx_first - 1) { [INFO] [stdout] 37 | | return true; [INFO] [stdout] 38 | | } [INFO] [stdout] 39 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 35 ~ if col_inx_first > 0 [INFO] [stdout] 36 ~ && is_symbol(&schematics, row_inx, col_inx_first - 1) { [INFO] [stdout] 37 | return true; [INFO] [stdout] 38 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:36:22 [INFO] [stdout] | [INFO] [stdout] 36 | if is_symbol(&schematics, row_inx, col_inx_first - 1) { [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/year2023/day3.rs:40:5 [INFO] [stdout] | [INFO] [stdout] 40 | / if col_inx_last < schematics[row_inx].len() - 1 { [INFO] [stdout] 41 | | if is_symbol(&schematics, row_inx, col_inx_last + 1) { [INFO] [stdout] 42 | | return true; [INFO] [stdout] 43 | | } [INFO] [stdout] 44 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 40 ~ if col_inx_last < schematics[row_inx].len() - 1 [INFO] [stdout] 41 ~ && is_symbol(&schematics, row_inx, col_inx_last + 1) { [INFO] [stdout] 42 | return true; [INFO] [stdout] 43 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:41:22 [INFO] [stdout] | [INFO] [stdout] 41 | if is_symbol(&schematics, row_inx, col_inx_last + 1) { [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:56:23 [INFO] [stdout] | [INFO] [stdout] 56 | if is_part_number(&schematics, row_inx, col_inx_first, col_inx_last) { [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `col_inx` is only used to index `schematics` [INFO] [stdout] --> src/year2023/day3.rs:58:24 [INFO] [stdout] | [INFO] [stdout] 58 | for col_inx in col_inx_first..col_inx_last + 1 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] help: consider using an iterator [INFO] [stdout] | [INFO] [stdout] 58 - for col_inx in col_inx_first..col_inx_last + 1 { [INFO] [stdout] 58 + for in schematics.iter().take(col_inx_last + 1).skip(col_inx_first) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function call inside of `expect` [INFO] [stdout] --> src/year2023/day3.rs:63:18 [INFO] [stdout] | [INFO] [stdout] 63 | .expect(format!("not a number!? {}", s).as_str()), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `unwrap_or_else(|_| panic!("not a number!? {}", s))` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#expect_fun_call [INFO] [stdout] = note: `#[warn(clippy::expect_fun_call)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/year2023/day3.rs:40:5 [INFO] [stdout] | [INFO] [stdout] 40 | / if col_inx_last < schematics[row_inx].len() - 1 { [INFO] [stdout] 41 | | if is_symbol(&schematics, row_inx, col_inx_last + 1) { [INFO] [stdout] 42 | | return true; [INFO] [stdout] 43 | | } [INFO] [stdout] 44 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 40 ~ if col_inx_last < schematics[row_inx].len() - 1 [INFO] [stdout] 41 ~ && is_symbol(&schematics, row_inx, col_inx_last + 1) { [INFO] [stdout] 42 | return true; [INFO] [stdout] 43 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:41:22 [INFO] [stdout] | [INFO] [stdout] 41 | if is_symbol(&schematics, row_inx, col_inx_last + 1) { [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:56:23 [INFO] [stdout] | [INFO] [stdout] 56 | if is_part_number(&schematics, row_inx, col_inx_first, col_inx_last) { [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `col_inx` is only used to index `schematics` [INFO] [stdout] --> src/year2023/day3.rs:58:24 [INFO] [stdout] | [INFO] [stdout] 58 | for col_inx in col_inx_first..col_inx_last + 1 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] help: consider using an iterator [INFO] [stdout] | [INFO] [stdout] 58 - for col_inx in col_inx_first..col_inx_last + 1 { [INFO] [stdout] 58 + for in schematics.iter().take(col_inx_last + 1).skip(col_inx_first) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function call inside of `expect` [INFO] [stdout] --> src/year2023/day3.rs:63:18 [INFO] [stdout] | [INFO] [stdout] 63 | .expect(format!("not a number!? {}", s).as_str()), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `unwrap_or_else(|_| panic!("not a number!? {}", s))` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#expect_fun_call [INFO] [stdout] = note: `#[warn(clippy::expect_fun_call)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day3.rs:79:5 [INFO] [stdout] | [INFO] [stdout] 79 | / contents [INFO] [stdout] 80 | | .lines() [INFO] [stdout] 81 | | .into_iter() [INFO] [stdout] | |____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 79 ~ contents [INFO] [stdout] 80 + .lines() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `.into_iter()` call is equivalent to `.iter()` and will not consume the `Vec` [INFO] [stdout] --> src/year2023/day3.rs:87:13 [INFO] [stdout] | [INFO] [stdout] 87 | row.into_iter().enumerate().for_each(|(col_inx, c)| { [INFO] [stdout] | ^^^^^^^^^ help: call directly: `iter` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#into_iter_on_ref [INFO] [stdout] = note: `#[warn(clippy::into_iter_on_ref)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day3.rs:79:5 [INFO] [stdout] | [INFO] [stdout] 79 | / contents [INFO] [stdout] 80 | | .lines() [INFO] [stdout] 81 | | .into_iter() [INFO] [stdout] | |____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 79 ~ contents [INFO] [stdout] 80 + .lines() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `.into_iter()` call is equivalent to `.iter()` and will not consume the `Vec` [INFO] [stdout] --> src/year2023/day3.rs:87:13 [INFO] [stdout] | [INFO] [stdout] 87 | row.into_iter().enumerate().for_each(|(col_inx, c)| { [INFO] [stdout] | ^^^^^^^^^ help: call directly: `iter` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#into_iter_on_ref [INFO] [stdout] = note: `#[warn(clippy::into_iter_on_ref)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day3.rs:119:17 [INFO] [stdout] | [INFO] [stdout] 119 | schematics: &Vec>, [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 119 - schematics: &Vec>, [INFO] [stdout] 119 + schematics: &[Vec], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day3.rs:119:17 [INFO] [stdout] | [INFO] [stdout] 119 | schematics: &Vec>, [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 119 - schematics: &Vec>, [INFO] [stdout] 119 + schematics: &[Vec], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: deref which would be done by auto-deref [INFO] [stdout] --> src/year2023/day3.rs:127:13 [INFO] [stdout] | [INFO] [stdout] 127 | (*val).0 += 1; // count [INFO] [stdout] | ^^^^^^ help: try: `val` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref [INFO] [stdout] = note: `#[warn(clippy::explicit_auto_deref)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: deref which would be done by auto-deref [INFO] [stdout] --> src/year2023/day3.rs:127:13 [INFO] [stdout] | [INFO] [stdout] 127 | (*val).0 += 1; // count [INFO] [stdout] | ^^^^^^ help: try: `val` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref [INFO] [stdout] = note: `#[warn(clippy::explicit_auto_deref)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: deref which would be done by auto-deref [INFO] [stdout] --> src/year2023/day3.rs:128:13 [INFO] [stdout] | [INFO] [stdout] 128 | (*val).1 *= number; // product [INFO] [stdout] | ^^^^^^ help: try: `val` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: deref which would be done by auto-deref [INFO] [stdout] --> src/year2023/day3.rs:128:13 [INFO] [stdout] | [INFO] [stdout] 128 | (*val).1 *= number; // product [INFO] [stdout] | ^^^^^^ help: try: `val` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `col_inx` is only used to index `schematics` [INFO] [stdout] --> src/year2023/day3.rs:144:20 [INFO] [stdout] | [INFO] [stdout] 144 | for col_inx in col_inx_first..col_inx_last + 1 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] help: consider using an iterator [INFO] [stdout] | [INFO] [stdout] 144 - for col_inx in col_inx_first..col_inx_last + 1 { [INFO] [stdout] 144 + for in schematics.iter().take(col_inx_last + 1).skip(col_inx_first) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function call inside of `expect` [INFO] [stdout] --> src/year2023/day3.rs:149:10 [INFO] [stdout] | [INFO] [stdout] 149 | .expect(format!("not a number!? {}", s).as_str()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `unwrap_or_else(|_| panic!("not a number!? {}", s))` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#expect_fun_call [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:155:50 [INFO] [stdout] | [INFO] [stdout] 155 | check_for_gear(number, gear_map, &schematics, row_inx - 1, col_inx as usize); [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:163:50 [INFO] [stdout] | [INFO] [stdout] 163 | check_for_gear(number, gear_map, &schematics, row_inx + 1, col_inx as usize); [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:169:42 [INFO] [stdout] | [INFO] [stdout] 169 | check_for_gear(number, gear_map, &schematics, row_inx, col_inx_first - 1); [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:172:42 [INFO] [stdout] | [INFO] [stdout] 172 | check_for_gear(number, gear_map, &schematics, row_inx, col_inx_last + 1); [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day3.rs:189:5 [INFO] [stdout] | [INFO] [stdout] 189 | / contents [INFO] [stdout] 190 | | .lines() [INFO] [stdout] 191 | | .into_iter() [INFO] [stdout] | |____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 189 ~ contents [INFO] [stdout] 190 + .lines() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `.into_iter()` call is equivalent to `.iter()` and will not consume the `Vec` [INFO] [stdout] --> src/year2023/day3.rs:197:13 [INFO] [stdout] | [INFO] [stdout] 197 | row.into_iter().enumerate().for_each(|(col_inx, c)| { [INFO] [stdout] | ^^^^^^^^^ help: call directly: `iter` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#into_iter_on_ref [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day4.rs:11:5 [INFO] [stdout] | [INFO] [stdout] 11 | contents.lines().into_iter().for_each(|line| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: found call to `str::trim` before `str::split_whitespace` [INFO] [stdout] --> src/year2023/day4.rs:16:14 [INFO] [stdout] | [INFO] [stdout] 16 | .trim() [INFO] [stdout] | ______________^ [INFO] [stdout] 17 | | .split_whitespace() [INFO] [stdout] | |_____________^ help: remove `trim()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#trim_split_whitespace [INFO] [stdout] = note: `#[warn(clippy::trim_split_whitespace)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting integer literal to `u32` is unnecessary [INFO] [stdout] --> src/year2023/day4.rs:27:20 [INFO] [stdout] | [INFO] [stdout] 27 | sum += (2 as u32).pow((count - 1) as u32); [INFO] [stdout] | ^^^^^^^^^^ help: try: `2_u32` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day4.rs:40:21 [INFO] [stdout] | [INFO] [stdout] 40 | let num_cards = contents.lines().into_iter().count(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day4.rs:43:5 [INFO] [stdout] | [INFO] [stdout] 43 | / contents [INFO] [stdout] 44 | | .lines() [INFO] [stdout] 45 | | .into_iter() [INFO] [stdout] | |____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 43 ~ contents [INFO] [stdout] 44 + .lines() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: found call to `str::trim` before `str::split_whitespace` [INFO] [stdout] --> src/year2023/day4.rs:52:18 [INFO] [stdout] | [INFO] [stdout] 52 | .trim() [INFO] [stdout] | __________________^ [INFO] [stdout] 53 | | .split_whitespace() [INFO] [stdout] | |_________________^ help: remove `trim()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#trim_split_whitespace [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `col_inx` is only used to index `schematics` [INFO] [stdout] --> src/year2023/day3.rs:144:20 [INFO] [stdout] | [INFO] [stdout] 144 | for col_inx in col_inx_first..col_inx_last + 1 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] help: consider using an iterator [INFO] [stdout] | [INFO] [stdout] 144 - for col_inx in col_inx_first..col_inx_last + 1 { [INFO] [stdout] 144 + for in schematics.iter().take(col_inx_last + 1).skip(col_inx_first) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function call inside of `expect` [INFO] [stdout] --> src/year2023/day3.rs:149:10 [INFO] [stdout] | [INFO] [stdout] 149 | .expect(format!("not a number!? {}", s).as_str()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `unwrap_or_else(|_| panic!("not a number!? {}", s))` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#expect_fun_call [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:155:50 [INFO] [stdout] | [INFO] [stdout] 155 | check_for_gear(number, gear_map, &schematics, row_inx - 1, col_inx as usize); [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:163:50 [INFO] [stdout] | [INFO] [stdout] 163 | check_for_gear(number, gear_map, &schematics, row_inx + 1, col_inx as usize); [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:169:42 [INFO] [stdout] | [INFO] [stdout] 169 | check_for_gear(number, gear_map, &schematics, row_inx, col_inx_first - 1); [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/year2023/day3.rs:172:42 [INFO] [stdout] | [INFO] [stdout] 172 | check_for_gear(number, gear_map, &schematics, row_inx, col_inx_last + 1); [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `schematics` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day3.rs:189:5 [INFO] [stdout] | [INFO] [stdout] 189 | / contents [INFO] [stdout] 190 | | .lines() [INFO] [stdout] 191 | | .into_iter() [INFO] [stdout] | |____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 189 ~ contents [INFO] [stdout] 190 + .lines() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `.into_iter()` call is equivalent to `.iter()` and will not consume the `Vec` [INFO] [stdout] --> src/year2023/day3.rs:197:13 [INFO] [stdout] | [INFO] [stdout] 197 | row.into_iter().enumerate().for_each(|(col_inx, c)| { [INFO] [stdout] | ^^^^^^^^^ help: call directly: `iter` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#into_iter_on_ref [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day4.rs:11:5 [INFO] [stdout] | [INFO] [stdout] 11 | contents.lines().into_iter().for_each(|line| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: found call to `str::trim` before `str::split_whitespace` [INFO] [stdout] --> src/year2023/day4.rs:16:14 [INFO] [stdout] | [INFO] [stdout] 16 | .trim() [INFO] [stdout] | ______________^ [INFO] [stdout] 17 | | .split_whitespace() [INFO] [stdout] | |_____________^ help: remove `trim()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#trim_split_whitespace [INFO] [stdout] = note: `#[warn(clippy::trim_split_whitespace)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting integer literal to `u32` is unnecessary [INFO] [stdout] --> src/year2023/day4.rs:27:20 [INFO] [stdout] | [INFO] [stdout] 27 | sum += (2 as u32).pow((count - 1) as u32); [INFO] [stdout] | ^^^^^^^^^^ help: try: `2_u32` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day4.rs:40:21 [INFO] [stdout] | [INFO] [stdout] 40 | let num_cards = contents.lines().into_iter().count(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day4.rs:43:5 [INFO] [stdout] | [INFO] [stdout] 43 | / contents [INFO] [stdout] 44 | | .lines() [INFO] [stdout] 45 | | .into_iter() [INFO] [stdout] | |____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 43 ~ contents [INFO] [stdout] 44 + .lines() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: found call to `str::trim` before `str::split_whitespace` [INFO] [stdout] --> src/year2023/day4.rs:52:18 [INFO] [stdout] | [INFO] [stdout] 52 | .trim() [INFO] [stdout] | __________________^ [INFO] [stdout] 53 | | .split_whitespace() [INFO] [stdout] | |_________________^ help: remove `trim()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#trim_split_whitespace [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `inx` is used to index `copies` [INFO] [stdout] --> src/year2023/day4.rs:63:24 [INFO] [stdout] | [INFO] [stdout] 63 | for inx in line_inx + 1..line_inx + 1 + count { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] help: consider using an iterator and enumerate() [INFO] [stdout] | [INFO] [stdout] 63 - for inx in line_inx + 1..line_inx + 1 + count { [INFO] [stdout] 63 + for (inx, ) in copies.iter_mut().enumerate().skip(line_inx + 1).take(count) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `inx` is used to index `copies` [INFO] [stdout] --> src/year2023/day4.rs:63:24 [INFO] [stdout] | [INFO] [stdout] 63 | for inx in line_inx + 1..line_inx + 1 + count { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] help: consider using an iterator and enumerate() [INFO] [stdout] | [INFO] [stdout] 63 - for inx in line_inx + 1..line_inx + 1 + count { [INFO] [stdout] 63 + for (inx, ) in copies.iter_mut().enumerate().skip(line_inx + 1).take(count) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day5.rs:39:18 [INFO] [stdout] | [INFO] [stdout] 39 | fn map2(sources: &Vec<(u64, u64)>, map: &Vec<(u64, u64, u64)>) -> Vec<(u64, u64)> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 39 ~ fn map2(sources: &[(u64, u64)], map: &Vec<(u64, u64, u64)>) -> Vec<(u64, u64)> { [INFO] [stdout] 40 | // Each map entry has the following values: [INFO] [stdout] ... [INFO] [stdout] 43 | let mut destinations: Vec<(u64, u64)> = Vec::new(); [INFO] [stdout] 44 ~ let mut sources_left = sources.to_owned(); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day5.rs:107:5 [INFO] [stdout] | [INFO] [stdout] 107 | contents.lines().into_iter().for_each(|line| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `current_map` after checking its variant with `is_none` [INFO] [stdout] --> src/year2023/day5.rs:122:25 [INFO] [stdout] | [INFO] [stdout] 118 | } else if current_map.is_none() { [INFO] [stdout] | ------------------------ help: try: `if let Some() = ¤t_map` [INFO] [stdout] ... [INFO] [stdout] 122 | maps.entry(*current_map.as_ref().unwrap()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] = note: `#[warn(clippy::unnecessary_unwrap)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Split<'_, char>` [INFO] [stdout] --> src/year2023/day5.rs:110:21 [INFO] [stdout] | [INFO] [stdout] 110 | seeds = numbers [INFO] [stdout] | _____________________^ [INFO] [stdout] 111 | | .trim() [INFO] [stdout] 112 | | .split(' ') [INFO] [stdout] 113 | | .into_iter() [INFO] [stdout] | |____________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 110 ~ seeds = numbers [INFO] [stdout] 111 + .trim() [INFO] [stdout] 112 + .split(' ') [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day5.rs:39:18 [INFO] [stdout] | [INFO] [stdout] 39 | fn map2(sources: &Vec<(u64, u64)>, map: &Vec<(u64, u64, u64)>) -> Vec<(u64, u64)> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 39 ~ fn map2(sources: &[(u64, u64)], map: &Vec<(u64, u64, u64)>) -> Vec<(u64, u64)> { [INFO] [stdout] 40 | // Each map entry has the following values: [INFO] [stdout] ... [INFO] [stdout] 43 | let mut destinations: Vec<(u64, u64)> = Vec::new(); [INFO] [stdout] 44 ~ let mut sources_left = sources.to_owned(); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day5.rs:107:5 [INFO] [stdout] | [INFO] [stdout] 107 | contents.lines().into_iter().for_each(|line| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `current_map` after checking its variant with `is_none` [INFO] [stdout] --> src/year2023/day5.rs:122:25 [INFO] [stdout] | [INFO] [stdout] 118 | } else if current_map.is_none() { [INFO] [stdout] | ------------------------ help: try: `if let Some() = ¤t_map` [INFO] [stdout] ... [INFO] [stdout] 122 | maps.entry(*current_map.as_ref().unwrap()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] = note: `#[warn(clippy::unnecessary_unwrap)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Split<'_, char>` [INFO] [stdout] --> src/year2023/day5.rs:110:21 [INFO] [stdout] | [INFO] [stdout] 110 | seeds = numbers [INFO] [stdout] | _____________________^ [INFO] [stdout] 111 | | .trim() [INFO] [stdout] 112 | | .split(' ') [INFO] [stdout] 113 | | .into_iter() [INFO] [stdout] | |____________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 110 ~ seeds = numbers [INFO] [stdout] 111 + .trim() [INFO] [stdout] 112 + .split(' ') [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: use of `or_insert` to construct default value [INFO] [stdout] --> src/year2023/day5.rs:123:18 [INFO] [stdout] | [INFO] [stdout] 123 | .or_insert(Vec::new()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: try: `or_default()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unwrap_or_default [INFO] [stdout] = note: `#[warn(clippy::unwrap_or_default)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: use of `or_insert` to construct default value [INFO] [stdout] --> src/year2023/day5.rs:123:18 [INFO] [stdout] | [INFO] [stdout] 123 | .or_insert(Vec::new()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: try: `or_default()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unwrap_or_default [INFO] [stdout] = note: `#[warn(clippy::unwrap_or_default)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day5.rs:163:5 [INFO] [stdout] | [INFO] [stdout] 163 | contents.lines().into_iter().for_each(|line| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `current_map` after checking its variant with `is_none` [INFO] [stdout] --> src/year2023/day5.rs:184:25 [INFO] [stdout] | [INFO] [stdout] 180 | } else if current_map.is_none() { [INFO] [stdout] | ------------------------ help: try: `if let Some() = ¤t_map` [INFO] [stdout] ... [INFO] [stdout] 184 | maps.entry(*current_map.as_ref().unwrap()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Split<'_, char>` [INFO] [stdout] --> src/year2023/day5.rs:166:21 [INFO] [stdout] | [INFO] [stdout] 166 | seeds = numbers [INFO] [stdout] | _____________________^ [INFO] [stdout] 167 | | .trim() [INFO] [stdout] 168 | | .split(' ') [INFO] [stdout] 169 | | .into_iter() [INFO] [stdout] | |____________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 166 ~ seeds = numbers [INFO] [stdout] 167 + .trim() [INFO] [stdout] 168 + .split(' ') [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day5.rs:163:5 [INFO] [stdout] | [INFO] [stdout] 163 | contents.lines().into_iter().for_each(|line| { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `contents.lines()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `current_map` after checking its variant with `is_none` [INFO] [stdout] --> src/year2023/day5.rs:184:25 [INFO] [stdout] | [INFO] [stdout] 180 | } else if current_map.is_none() { [INFO] [stdout] | ------------------------ help: try: `if let Some() = ¤t_map` [INFO] [stdout] ... [INFO] [stdout] 184 | maps.entry(*current_map.as_ref().unwrap()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Split<'_, char>` [INFO] [stdout] --> src/year2023/day5.rs:166:21 [INFO] [stdout] | [INFO] [stdout] 166 | seeds = numbers [INFO] [stdout] | _____________________^ [INFO] [stdout] 167 | | .trim() [INFO] [stdout] 168 | | .split(' ') [INFO] [stdout] 169 | | .into_iter() [INFO] [stdout] | |____________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 166 ~ seeds = numbers [INFO] [stdout] 167 + .trim() [INFO] [stdout] 168 + .split(' ') [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: use of `or_insert` to construct default value [INFO] [stdout] --> src/year2023/day5.rs:185:18 [INFO] [stdout] | [INFO] [stdout] 185 | .or_insert(Vec::new()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: try: `or_default()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unwrap_or_default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: use of `or_insert` to construct default value [INFO] [stdout] --> src/year2023/day5.rs:185:18 [INFO] [stdout] | [INFO] [stdout] 185 | .or_insert(Vec::new()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: try: `or_default()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unwrap_or_default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day6.rs:3:18 [INFO] [stdout] | [INFO] [stdout] 3 | fn compute(time: &Vec, dist: &Vec) -> u64 { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 3 - fn compute(time: &Vec, dist: &Vec) -> u64 { [INFO] [stdout] 3 + fn compute(time: &[u64], dist: &Vec) -> u64 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day6.rs:3:18 [INFO] [stdout] | [INFO] [stdout] 3 | fn compute(time: &Vec, dist: &Vec) -> u64 { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 3 - fn compute(time: &Vec, dist: &Vec) -> u64 { [INFO] [stdout] 3 + fn compute(time: &[u64], dist: &Vec) -> u64 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day6.rs:3:35 [INFO] [stdout] | [INFO] [stdout] 3 | fn compute(time: &Vec, dist: &Vec) -> u64 { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 3 - fn compute(time: &Vec, dist: &Vec) -> u64 { [INFO] [stdout] 3 + fn compute(time: &Vec, dist: &[u64]) -> u64 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/year2023/day6.rs:3:35 [INFO] [stdout] | [INFO] [stdout] 3 | fn compute(time: &Vec, dist: &Vec) -> u64 { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 3 - fn compute(time: &Vec, dist: &Vec) -> u64 { [INFO] [stdout] 3 + fn compute(time: &Vec, dist: &[u64]) -> u64 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Split<'_, fn(char) -> bool {std::char::methods::::is_whitespace}>` [INFO] [stdout] --> src/year2023/day6.rs:38:22 [INFO] [stdout] | [INFO] [stdout] 38 | let values = line [INFO] [stdout] | ______________________^ [INFO] [stdout] 39 | | .split_once(':') [INFO] [stdout] 40 | | .unwrap() [INFO] [stdout] 41 | | .1 [INFO] [stdout] 42 | | .trim() [INFO] [stdout] 43 | | .split(char::is_whitespace) [INFO] [stdout] 44 | | .into_iter() [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 38 ~ let values = line [INFO] [stdout] 39 + .split_once(':') [INFO] [stdout] 40 + .unwrap() [INFO] [stdout] 41 + .1 [INFO] [stdout] 42 + .trim() [INFO] [stdout] 43 + .split(char::is_whitespace) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Split<'_, fn(char) -> bool {std::char::methods::::is_whitespace}>` [INFO] [stdout] --> src/year2023/day6.rs:38:22 [INFO] [stdout] | [INFO] [stdout] 38 | let values = line [INFO] [stdout] | ______________________^ [INFO] [stdout] 39 | | .split_once(':') [INFO] [stdout] 40 | | .unwrap() [INFO] [stdout] 41 | | .1 [INFO] [stdout] 42 | | .trim() [INFO] [stdout] 43 | | .split(char::is_whitespace) [INFO] [stdout] 44 | | .into_iter() [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 38 ~ let values = line [INFO] [stdout] 39 + .split_once(':') [INFO] [stdout] 40 + .unwrap() [INFO] [stdout] 41 + .1 [INFO] [stdout] 42 + .trim() [INFO] [stdout] 43 + .split(char::is_whitespace) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function call inside of `expect` [INFO] [stdout] --> src/year2023/day6.rs:46:39 [INFO] [stdout] | [INFO] [stdout] 46 | .map(|n| n.parse::().expect(format!("n=|{}|", n).as_str())) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `unwrap_or_else(|_| panic!("n=|{}|", n))` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#expect_fun_call [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function call inside of `expect` [INFO] [stdout] --> src/year2023/day6.rs:46:39 [INFO] [stdout] | [INFO] [stdout] 46 | .map(|n| n.parse::().expect(format!("n=|{}|", n).as_str())) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `unwrap_or_else(|_| panic!("n=|{}|", n))` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#expect_fun_call [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: found call to `str::trim` before `str::split_whitespace` [INFO] [stdout] --> src/year2023/day6.rs:74:14 [INFO] [stdout] | [INFO] [stdout] 74 | .trim() [INFO] [stdout] | ______________^ [INFO] [stdout] 75 | | .split_whitespace() [INFO] [stdout] | |_____________^ help: remove `trim()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#trim_split_whitespace [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: found call to `str::trim` before `str::split_whitespace` [INFO] [stdout] --> src/year2023/day6.rs:74:14 [INFO] [stdout] | [INFO] [stdout] 74 | .trim() [INFO] [stdout] | ______________^ [INFO] [stdout] 75 | | .split_whitespace() [INFO] [stdout] | |_____________^ help: remove `trim()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#trim_split_whitespace [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/year2023/day7.rs:78:12 [INFO] [stdout] | [INFO] [stdout] 78 | if (a == b && b == c && c == d) || (b == c && c == d && d == e) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 78 - if (a == b && b == c && c == d) || (b == c && c == d && d == e) { [INFO] [stdout] 78 + if !(b != c || c != d || a != b && d != e) { [INFO] [stdout] | [INFO] [stdout] 78 - if (a == b && b == c && c == d) || (b == c && c == d && d == e) { [INFO] [stdout] 78 + if (d == e || a == b) && c == d && b == c { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/year2023/day7.rs:81:12 [INFO] [stdout] | [INFO] [stdout] 81 | if ((a == b && b == c) && (d == e)) || ((a == b) && (c == d && d == e)) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 81 - if ((a == b && b == c) && (d == e)) || ((a == b) && (c == d && d == e)) { [INFO] [stdout] 81 + if !(a != b || d != e || b != c && c != d) { [INFO] [stdout] | [INFO] [stdout] 81 - if ((a == b && b == c) && (d == e)) || ((a == b) && (c == d && d == e)) { [INFO] [stdout] 81 + if (c == d || b == c) && (d == e) && a == b { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/year2023/day7.rs:84:12 [INFO] [stdout] | [INFO] [stdout] 84 | if (a == b && b == c) || (b == c && c == d) || (c == d && d == e) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 84 - if (a == b && b == c) || (b == c && c == d) || (c == d && d == e) { [INFO] [stdout] 84 + if !(b != c || a != b && c != d) || (c == d && d == e) { [INFO] [stdout] | [INFO] [stdout] 84 - if (a == b && b == c) || (b == c && c == d) || (c == d && d == e) { [INFO] [stdout] 84 + if (c == d || a == b) && b == c || (c == d && d == e) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/year2023/day7.rs:87:12 [INFO] [stdout] | [INFO] [stdout] 87 | if (a == b && c == d) || (a == b && d == e) || (b == c && d == e) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 87 - if (a == b && c == d) || (a == b && d == e) || (b == c && d == e) { [INFO] [stdout] 87 + if !(a != b || c != d && d != e) || (b == c && d == e) { [INFO] [stdout] | [INFO] [stdout] 87 - if (a == b && c == d) || (a == b && d == e) || (b == c && d == e) { [INFO] [stdout] 87 + if (d == e || c == d) && a == b || (b == c && d == e) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `[Value; 5]` which implements the `Copy` trait [INFO] [stdout] --> src/year2023/day7.rs:72:30 [INFO] [stdout] | [INFO] [stdout] 72 | let mut cards_copy = cards.clone(); [INFO] [stdout] | ^^^^^^^^^^^^^ help: try dereferencing it: `*cards` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] = note: `#[warn(clippy::clone_on_copy)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/year2023/day7.rs:78:12 [INFO] [stdout] | [INFO] [stdout] 78 | if (a == b && b == c && c == d) || (b == c && c == d && d == e) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 78 - if (a == b && b == c && c == d) || (b == c && c == d && d == e) { [INFO] [stdout] 78 + if !(b != c || c != d || a != b && d != e) { [INFO] [stdout] | [INFO] [stdout] 78 - if (a == b && b == c && c == d) || (b == c && c == d && d == e) { [INFO] [stdout] 78 + if (d == e || a == b) && c == d && b == c { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/year2023/day7.rs:81:12 [INFO] [stdout] | [INFO] [stdout] 81 | if ((a == b && b == c) && (d == e)) || ((a == b) && (c == d && d == e)) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 81 - if ((a == b && b == c) && (d == e)) || ((a == b) && (c == d && d == e)) { [INFO] [stdout] 81 + if !(a != b || d != e || b != c && c != d) { [INFO] [stdout] | [INFO] [stdout] 81 - if ((a == b && b == c) && (d == e)) || ((a == b) && (c == d && d == e)) { [INFO] [stdout] 81 + if (c == d || b == c) && (d == e) && a == b { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/year2023/day7.rs:84:12 [INFO] [stdout] | [INFO] [stdout] 84 | if (a == b && b == c) || (b == c && c == d) || (c == d && d == e) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 84 - if (a == b && b == c) || (b == c && c == d) || (c == d && d == e) { [INFO] [stdout] 84 + if !(b != c || a != b && c != d) || (c == d && d == e) { [INFO] [stdout] | [INFO] [stdout] 84 - if (a == b && b == c) || (b == c && c == d) || (c == d && d == e) { [INFO] [stdout] 84 + if (c == d || a == b) && b == c || (c == d && d == e) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/year2023/day7.rs:87:12 [INFO] [stdout] | [INFO] [stdout] 87 | if (a == b && c == d) || (a == b && d == e) || (b == c && d == e) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 87 - if (a == b && c == d) || (a == b && d == e) || (b == c && d == e) { [INFO] [stdout] 87 + if !(a != b || c != d && d != e) || (b == c && d == e) { [INFO] [stdout] | [INFO] [stdout] 87 - if (a == b && c == d) || (a == b && d == e) || (b == c && d == e) { [INFO] [stdout] 87 + if (d == e || c == d) && a == b || (b == c && d == e) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `[Value; 5]` which implements the `Copy` trait [INFO] [stdout] --> src/year2023/day7.rs:72:30 [INFO] [stdout] | [INFO] [stdout] 72 | let mut cards_copy = cards.clone(); [INFO] [stdout] | ^^^^^^^^^^^^^ help: try dereferencing it: `*cards` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] = note: `#[warn(clippy::clone_on_copy)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `.into_iter()` call is equivalent to `.iter()` and will not consume the `array` [INFO] [stdout] --> src/year2023/day7.rs:99:15 [INFO] [stdout] | [INFO] [stdout] 99 | cards.into_iter().enumerate().for_each(|(inx, card)| { [INFO] [stdout] | ^^^^^^^^^ help: call directly: `iter` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#into_iter_on_ref [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `.into_iter()` call is equivalent to `.iter()` and will not consume the `array` [INFO] [stdout] --> src/year2023/day7.rs:113:15 [INFO] [stdout] | [INFO] [stdout] 113 | cards.into_iter().for_each(|card| { [INFO] [stdout] | ^^^^^^^^^ help: call directly: `iter` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#into_iter_on_ref [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `[Value; 5]` which implements the `Copy` trait [INFO] [stdout] --> src/year2023/day7.rs:115:39 [INFO] [stdout] | [INFO] [stdout] 115 | let mut cards_clone = cards.clone(); [INFO] [stdout] | ^^^^^^^^^^^^^ help: try dereferencing it: `*cards` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `.into_iter()` call is equivalent to `.iter()` and will not consume the `array` [INFO] [stdout] --> src/year2023/day7.rs:99:15 [INFO] [stdout] | [INFO] [stdout] 99 | cards.into_iter().enumerate().for_each(|(inx, card)| { [INFO] [stdout] | ^^^^^^^^^ help: call directly: `iter` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#into_iter_on_ref [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `.into_iter()` call is equivalent to `.iter()` and will not consume the `array` [INFO] [stdout] --> src/year2023/day7.rs:113:15 [INFO] [stdout] | [INFO] [stdout] 113 | cards.into_iter().for_each(|card| { [INFO] [stdout] | ^^^^^^^^^ help: call directly: `iter` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#into_iter_on_ref [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `[Value; 5]` which implements the `Copy` trait [INFO] [stdout] --> src/year2023/day7.rs:115:39 [INFO] [stdout] | [INFO] [stdout] 115 | let mut cards_clone = cards.clone(); [INFO] [stdout] | ^^^^^^^^^^^^^ help: try dereferencing it: `*cards` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day7.rs:172:21 [INFO] [stdout] | [INFO] [stdout] 172 | let mut hands = contents [INFO] [stdout] | _____________________^ [INFO] [stdout] 173 | | .lines() [INFO] [stdout] 174 | | .into_iter() [INFO] [stdout] | |____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 172 ~ let mut hands = contents [INFO] [stdout] 173 + .lines() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day7.rs:172:21 [INFO] [stdout] | [INFO] [stdout] 172 | let mut hands = contents [INFO] [stdout] | _____________________^ [INFO] [stdout] 173 | | .lines() [INFO] [stdout] 174 | | .into_iter() [INFO] [stdout] | |____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 172 ~ let mut hands = contents [INFO] [stdout] 173 + .lines() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day7.rs:203:21 [INFO] [stdout] | [INFO] [stdout] 203 | let mut hands = contents [INFO] [stdout] | _____________________^ [INFO] [stdout] 204 | | .lines() [INFO] [stdout] 205 | | .into_iter() [INFO] [stdout] | |____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 203 ~ let mut hands = contents [INFO] [stdout] 204 + .lines() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day7.rs:203:21 [INFO] [stdout] | [INFO] [stdout] 203 | let mut hands = contents [INFO] [stdout] | _____________________^ [INFO] [stdout] 204 | | .lines() [INFO] [stdout] 205 | | .into_iter() [INFO] [stdout] | |____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 203 ~ let mut hands = contents [INFO] [stdout] 204 + .lines() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day8.rs:29:5 [INFO] [stdout] | [INFO] [stdout] 29 | / contents [INFO] [stdout] 30 | | .lines() [INFO] [stdout] 31 | | .into_iter() [INFO] [stdout] | |____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 29 ~ contents [INFO] [stdout] 30 + .lines() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day8.rs:29:5 [INFO] [stdout] | [INFO] [stdout] 29 | / contents [INFO] [stdout] 30 | | .lines() [INFO] [stdout] 31 | | .into_iter() [INFO] [stdout] | |____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 29 ~ contents [INFO] [stdout] 30 + .lines() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `map(..).flatten()` on `Iterator` [INFO] [stdout] --> src/year2023/day8.rs:38:22 [INFO] [stdout] | [INFO] [stdout] 38 | .map(|c| match c { [INFO] [stdout] | ______________________^ [INFO] [stdout] 39 | | 'L' => Some(Direction::L), [INFO] [stdout] 40 | | 'R' => Some(Direction::R), [INFO] [stdout] 41 | | _ => None, [INFO] [stdout] 42 | | }) [INFO] [stdout] 43 | | .flatten() [INFO] [stdout] | |______________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_flatten [INFO] [stdout] = note: `#[warn(clippy::map_flatten)]` on by default [INFO] [stdout] help: try replacing `map` with `filter_map` and remove the `.flatten()` [INFO] [stdout] | [INFO] [stdout] 38 ~ .filter_map(|c| match c { [INFO] [stdout] 39 + 'L' => Some(Direction::L), [INFO] [stdout] 40 + 'R' => Some(Direction::R), [INFO] [stdout] 41 + _ => None, [INFO] [stdout] 42 + }) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `map(..).flatten()` on `Iterator` [INFO] [stdout] --> src/year2023/day8.rs:38:22 [INFO] [stdout] | [INFO] [stdout] 38 | .map(|c| match c { [INFO] [stdout] | ______________________^ [INFO] [stdout] 39 | | 'L' => Some(Direction::L), [INFO] [stdout] 40 | | 'R' => Some(Direction::R), [INFO] [stdout] 41 | | _ => None, [INFO] [stdout] 42 | | }) [INFO] [stdout] 43 | | .flatten() [INFO] [stdout] | |______________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_flatten [INFO] [stdout] = note: `#[warn(clippy::map_flatten)]` on by default [INFO] [stdout] help: try replacing `map` with `filter_map` and remove the `.flatten()` [INFO] [stdout] | [INFO] [stdout] 38 ~ .filter_map(|c| match c { [INFO] [stdout] 39 + 'L' => Some(Direction::L), [INFO] [stdout] 40 + 'R' => Some(Direction::R), [INFO] [stdout] 41 + _ => None, [INFO] [stdout] 42 + }) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Chars<'_>` [INFO] [stdout] --> src/year2023/day8.rs:35:32 [INFO] [stdout] | [INFO] [stdout] 35 | instructions = line [INFO] [stdout] | ________________________________^ [INFO] [stdout] 36 | | .chars() [INFO] [stdout] 37 | | .into_iter() [INFO] [stdout] | |________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 35 ~ instructions = line [INFO] [stdout] 36 + .chars() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Chars<'_>` [INFO] [stdout] --> src/year2023/day8.rs:35:32 [INFO] [stdout] | [INFO] [stdout] 35 | instructions = line [INFO] [stdout] | ________________________________^ [INFO] [stdout] 36 | | .chars() [INFO] [stdout] 37 | | .into_iter() [INFO] [stdout] | |________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 35 ~ instructions = line [INFO] [stdout] 36 + .chars() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day8.rs:84:5 [INFO] [stdout] | [INFO] [stdout] 84 | / contents [INFO] [stdout] 85 | | .lines() [INFO] [stdout] 86 | | .into_iter() [INFO] [stdout] | |____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 84 ~ contents [INFO] [stdout] 85 + .lines() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `map(..).flatten()` on `Iterator` [INFO] [stdout] --> src/year2023/day8.rs:93:22 [INFO] [stdout] | [INFO] [stdout] 93 | .map(|c| match c { [INFO] [stdout] | ______________________^ [INFO] [stdout] 94 | | 'L' => Some(Direction::L), [INFO] [stdout] 95 | | 'R' => Some(Direction::R), [INFO] [stdout] 96 | | _ => None, [INFO] [stdout] 97 | | }) [INFO] [stdout] 98 | | .flatten() [INFO] [stdout] | |______________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_flatten [INFO] [stdout] help: try replacing `map` with `filter_map` and remove the `.flatten()` [INFO] [stdout] | [INFO] [stdout] 93 ~ .filter_map(|c| match c { [INFO] [stdout] 94 + 'L' => Some(Direction::L), [INFO] [stdout] 95 + 'R' => Some(Direction::R), [INFO] [stdout] 96 + _ => None, [INFO] [stdout] 97 + }) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Chars<'_>` [INFO] [stdout] --> src/year2023/day8.rs:90:32 [INFO] [stdout] | [INFO] [stdout] 90 | instructions = line [INFO] [stdout] | ________________________________^ [INFO] [stdout] 91 | | .chars() [INFO] [stdout] 92 | | .into_iter() [INFO] [stdout] | |________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 90 ~ instructions = line [INFO] [stdout] 91 + .chars() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Lines<'_>` [INFO] [stdout] --> src/year2023/day8.rs:84:5 [INFO] [stdout] | [INFO] [stdout] 84 | / contents [INFO] [stdout] 85 | | .lines() [INFO] [stdout] 86 | | .into_iter() [INFO] [stdout] | |____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 84 ~ contents [INFO] [stdout] 85 + .lines() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `map(..).flatten()` on `Iterator` [INFO] [stdout] --> src/year2023/day8.rs:93:22 [INFO] [stdout] | [INFO] [stdout] 93 | .map(|c| match c { [INFO] [stdout] | ______________________^ [INFO] [stdout] 94 | | 'L' => Some(Direction::L), [INFO] [stdout] 95 | | 'R' => Some(Direction::R), [INFO] [stdout] 96 | | _ => None, [INFO] [stdout] 97 | | }) [INFO] [stdout] 98 | | .flatten() [INFO] [stdout] | |______________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_flatten [INFO] [stdout] help: try replacing `map` with `filter_map` and remove the `.flatten()` [INFO] [stdout] | [INFO] [stdout] 93 ~ .filter_map(|c| match c { [INFO] [stdout] 94 + 'L' => Some(Direction::L), [INFO] [stdout] 95 + 'R' => Some(Direction::R), [INFO] [stdout] 96 + _ => None, [INFO] [stdout] 97 + }) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Chars<'_>` [INFO] [stdout] --> src/year2023/day8.rs:90:32 [INFO] [stdout] | [INFO] [stdout] 90 | instructions = line [INFO] [stdout] | ________________________________^ [INFO] [stdout] 91 | | .chars() [INFO] [stdout] 92 | | .into_iter() [INFO] [stdout] | |________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 90 ~ instructions = line [INFO] [stdout] 91 + .chars() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::SplitWhitespace<'_>` [INFO] [stdout] --> src/year2023/day9.rs:7:27 [INFO] [stdout] | [INFO] [stdout] 7 | let mut numbers = line [INFO] [stdout] | ___________________________^ [INFO] [stdout] 8 | | .split_whitespace() [INFO] [stdout] 9 | | .into_iter() [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 7 ~ let mut numbers = line [INFO] [stdout] 8 + .split_whitespace() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::SplitWhitespace<'_>` [INFO] [stdout] --> src/year2023/day9.rs:7:27 [INFO] [stdout] | [INFO] [stdout] 7 | let mut numbers = line [INFO] [stdout] | ___________________________^ [INFO] [stdout] 8 | | .split_whitespace() [INFO] [stdout] 9 | | .into_iter() [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] help: consider removing `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 7 ~ let mut numbers = line [INFO] [stdout] 8 + .split_whitespace() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `inx` is only used to index `numbers` [INFO] [stdout] --> src/year2023/day9.rs:31:28 [INFO] [stdout] | [INFO] [stdout] 31 | for inx in outer_inx..numbers.len() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] help: consider using an iterator [INFO] [stdout] | [INFO] [stdout] 31 - for inx in outer_inx..numbers.len() { [INFO] [stdout] 31 + for in numbers.iter().skip(outer_inx) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `inx` is only used to index `numbers` [INFO] [stdout] --> src/year2023/day9.rs:31:28 [INFO] [stdout] | [INFO] [stdout] 31 | for inx in outer_inx..numbers.len() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] help: consider using an iterator [INFO] [stdout] | [INFO] [stdout] 31 - for inx in outer_inx..numbers.len() { [INFO] [stdout] 31 + for in numbers.iter().skip(outer_inx) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `swapItem` should have a snake case name [INFO] [stdout] --> src/year2023/day13.rs:63:4 [INFO] [stdout] | [INFO] [stdout] 63 | fn swapItem(item: Item) -> Item { [INFO] [stdout] | ^^^^^^^^ help: convert the identifier to snake case: `swap_item` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_snake_case)]` (part of `#[warn(nonstandard_style)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `swapItem` should have a snake case name [INFO] [stdout] --> src/year2023/day13.rs:63:4 [INFO] [stdout] | [INFO] [stdout] 63 | fn swapItem(item: Item) -> Item { [INFO] [stdout] | ^^^^^^^^ help: convert the identifier to snake case: `swap_item` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_snake_case)]` (part of `#[warn(nonstandard_style)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 7.24s [INFO] running `Command { std: "docker" "inspect" "6fa8a2426cf12627eaf7565d2f7689e0eff3de0e43299d2844cf129c227a77e9", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "6fa8a2426cf12627eaf7565d2f7689e0eff3de0e43299d2844cf129c227a77e9", kill_on_drop: false }` [INFO] [stdout] 6fa8a2426cf12627eaf7565d2f7689e0eff3de0e43299d2844cf129c227a77e9