[INFO] cloning repository https://github.com/errantsky/adventofcode-2017 [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/errantsky/adventofcode-2017" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Ferrantsky%2Fadventofcode-2017", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Ferrantsky%2Fadventofcode-2017'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 5905e5fad6f49342a47488a5fc6cd574bfc3cd7e [INFO] linting errantsky/adventofcode-2017 against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Ferrantsky%2Fadventofcode-2017" "/workspace/builds/worker-3-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-3-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/errantsky/adventofcode-2017 [INFO] finished tweaking git repo https://github.com/errantsky/adventofcode-2017 [INFO] tweaked toml for git repo https://github.com/errantsky/adventofcode-2017 written to /workspace/builds/worker-3-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/errantsky/adventofcode-2017 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/errantsky/adventofcode-2017 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] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-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] 756cf2b0f20936f7ca780b0e55de602192fdba4038dc8244cdf8bfc496e816a6 [INFO] running `Command { std: "docker" "start" "-a" "756cf2b0f20936f7ca780b0e55de602192fdba4038dc8244cdf8bfc496e816a6", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "756cf2b0f20936f7ca780b0e55de602192fdba4038dc8244cdf8bfc496e816a6", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "756cf2b0f20936f7ca780b0e55de602192fdba4038dc8244cdf8bfc496e816a6", kill_on_drop: false }` [INFO] [stdout] 756cf2b0f20936f7ca780b0e55de602192fdba4038dc8244cdf8bfc496e816a6 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-3-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] 97ad1faab45c18619239ae74887381a58704ec032022d0eead13832a29fae870 [INFO] running `Command { std: "docker" "start" "-a" "97ad1faab45c18619239ae74887381a58704ec032022d0eead13832a29fae870", kill_on_drop: false }` [INFO] [stderr] Checking regex-syntax v0.6.25 [INFO] [stderr] Checking aho-corasick v0.7.18 [INFO] [stderr] Checking regex v1.5.4 [INFO] [stderr] Checking adventofcode-2017 v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unused imports: `part1` and `part2` [INFO] [stdout] --> src/main.rs:1:36 [INFO] [stdout] | [INFO] [stdout] 1 | use crate::dueling_generators_15::{part1, part2}; [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: `std::hash::Hash` [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use std::hash::Hash; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::hash::Hash` [INFO] [stdout] --> src/digital_plumber_12.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use std::hash::Hash; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::hash::Hash` [INFO] [stdout] --> src/duet_18.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use std::hash::Hash; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fs::File` [INFO] [stdout] --> src/electromagnetic_moat_24.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use std::fs::File; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `BufRead` and `BufReader` [INFO] [stdout] --> src/electromagnetic_moat_24.rs:3:15 [INFO] [stdout] | [INFO] [stdout] 3 | use std::io::{BufRead, BufReader}; [INFO] [stdout] | ^^^^^^^ ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `HashSet` [INFO] [stdout] --> src/memory_realloc_6.rs:1:33 [INFO] [stdout] | [INFO] [stdout] 1 | use std::collections::{HashMap, HashSet}; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fs::File` [INFO] [stdout] --> src/memory_realloc_6.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use std::fs::File; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `BufRead` and `BufReader` [INFO] [stdout] --> src/memory_realloc_6.rs:3:15 [INFO] [stdout] | [INFO] [stdout] 3 | use std::io::{BufRead, BufReader}; [INFO] [stdout] | ^^^^^^^ ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `HashSet` [INFO] [stdout] --> src/packet_scanners_13.rs:1:33 [INFO] [stdout] | [INFO] [stdout] 1 | use std::collections::{HashMap, HashSet}; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::collections::HashMap` [INFO] [stdout] --> src/permutation_promenade_16.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::collections::HashMap; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `BufRead` [INFO] [stdout] --> src/registers_8.rs:3:15 [INFO] [stdout] | [INFO] [stdout] 3 | use std::io::{BufRead, BufReader, Lines}; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around function argument [INFO] [stdout] --> src/spiral_memory_3.rs:87:28 [INFO] [stdout] | [INFO] [stdout] 87 | let quadrant = mod_pos((p - zero), layer_len) / (2 * layer); [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 87 - let quadrant = mod_pos((p - zero), layer_len) / (2 * layer); [INFO] [stdout] 87 + let quadrant = mod_pos(p - zero, layer_len) / (2 * layer); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fs::File` [INFO] [stdout] --> src/stream_processing_9.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::fs::File; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `BufRead` and `BufReader` [INFO] [stdout] --> src/stream_processing_9.rs:2:15 [INFO] [stdout] | [INFO] [stdout] 2 | use std::io::{BufRead, BufReader}; [INFO] [stdout] | ^^^^^^^ ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `part1` and `part2` [INFO] [stdout] --> src/main.rs:1:36 [INFO] [stdout] | [INFO] [stdout] 1 | use crate::dueling_generators_15::{part1, part2}; [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: `std::hash::Hash` [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use std::hash::Hash; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fs::File` [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:133:9 [INFO] [stdout] | [INFO] [stdout] 133 | use std::fs::File; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `BufRead`, `BufReader`, and `Split` [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:134:19 [INFO] [stdout] | [INFO] [stdout] 134 | use std::io::{BufRead, BufReader, Split}; [INFO] [stdout] | ^^^^^^^ ^^^^^^^^^ ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::hash::Hash` [INFO] [stdout] --> src/digital_plumber_12.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use std::hash::Hash; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::hash::Hash` [INFO] [stdout] --> src/duet_18.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use std::hash::Hash; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fs::File` [INFO] [stdout] --> src/duet_18.rs:121:9 [INFO] [stdout] | [INFO] [stdout] 121 | use std::fs::File; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `BufRead`, `BufReader`, and `Split` [INFO] [stdout] --> src/duet_18.rs:122:19 [INFO] [stdout] | [INFO] [stdout] 122 | use std::io::{BufRead, BufReader, Split}; [INFO] [stdout] | ^^^^^^^ ^^^^^^^^^ ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fs::File` [INFO] [stdout] --> src/electromagnetic_moat_24.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use std::fs::File; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `BufRead` and `BufReader` [INFO] [stdout] --> src/electromagnetic_moat_24.rs:3:15 [INFO] [stdout] | [INFO] [stdout] 3 | use std::io::{BufRead, BufReader}; [INFO] [stdout] | ^^^^^^^ ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `super::*` [INFO] [stdout] --> src/electromagnetic_moat_24.rs:36:9 [INFO] [stdout] | [INFO] [stdout] 36 | use super::*; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `HashSet` [INFO] [stdout] --> src/memory_realloc_6.rs:1:33 [INFO] [stdout] | [INFO] [stdout] 1 | use std::collections::{HashMap, HashSet}; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `HashSet` [INFO] [stdout] --> src/packet_scanners_13.rs:1:33 [INFO] [stdout] | [INFO] [stdout] 1 | use std::collections::{HashMap, HashSet}; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fs::read` [INFO] [stdout] --> src/packet_scanners_13.rs:70:9 [INFO] [stdout] | [INFO] [stdout] 70 | use std::fs::read; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::collections::HashMap` [INFO] [stdout] --> src/particle_swarm_20.rs:60:9 [INFO] [stdout] | [INFO] [stdout] 60 | use std::collections::HashMap; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::collections::HashMap` [INFO] [stdout] --> src/permutation_promenade_16.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::collections::HashMap; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::dueling_generators_15::part2` [INFO] [stdout] --> src/permutation_promenade_16.rs:32:9 [INFO] [stdout] | [INFO] [stdout] 32 | use crate::dueling_generators_15::part2; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::hash::Hash` [INFO] [stdout] --> src/spinlock_17.rs:12:9 [INFO] [stdout] | [INFO] [stdout] 12 | use std::hash::Hash; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around function argument [INFO] [stdout] --> src/spiral_memory_3.rs:87:28 [INFO] [stdout] | [INFO] [stdout] 87 | let quadrant = mod_pos((p - zero), layer_len) / (2 * layer); [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 87 - let quadrant = mod_pos((p - zero), layer_len) / (2 * layer); [INFO] [stdout] 87 + let quadrant = mod_pos(p - zero, layer_len) / (2 * layer); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:15:13 [INFO] [stdout] | [INFO] [stdout] 15 | let mut lc = line_cursor as usize; [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: unused variable: `lc` [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:15:13 [INFO] [stdout] | [INFO] [stdout] 15 | let mut lc = line_cursor as usize; [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_lc` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `c` [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:54:33 [INFO] [stdout] | [INFO] [stdout] 54 | Field::Register(c) => { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_c` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/digital_plumber_12.rs:75:13 [INFO] [stdout] | [INFO] [stdout] 75 | let mut split_line: Vec<&str> = line.split(" <-> ").collect(); [INFO] [stdout] | ----^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/dueling_generators_15.rs:12:9 [INFO] [stdout] | [INFO] [stdout] 12 | for i in 0..(40 * 10_usize.pow(6)) { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/dueling_generators_15.rs:27:9 [INFO] [stdout] | [INFO] [stdout] 27 | for i in 0..(5 * 10_usize.pow(6)) { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/duet_18.rs:11:13 [INFO] [stdout] | [INFO] [stdout] 11 | let mut lc = line_cursor as usize; [INFO] [stdout] | ----^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `lc` [INFO] [stdout] --> src/duet_18.rs:11:13 [INFO] [stdout] | [INFO] [stdout] 11 | let mut lc = line_cursor as usize; [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_lc` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/halting_problem_25.rs:9:9 [INFO] [stdout] | [INFO] [stdout] 9 | for i in 0..count { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/halting_problem_25.rs:59:9 [INFO] [stdout] | [INFO] [stdout] 59 | for i in 0..count { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/memory_realloc_6.rs:11:23 [INFO] [stdout] | [INFO] [stdout] 11 | let (mut mid, mut mval) = banks [INFO] [stdout] | ----^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/memory_realloc_6.rs:24:13 [INFO] [stdout] | [INFO] [stdout] 24 | for i in 0..blocks { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `range` [INFO] [stdout] --> src/packet_scanners_13.rs:7:17 [INFO] [stdout] | [INFO] [stdout] 7 | for (depth, range) in scanners.iter() { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_range` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `range` [INFO] [stdout] --> src/packet_scanners_13.rs:11:17 [INFO] [stdout] | [INFO] [stdout] 11 | for (depth, range) in scanners.iter() { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_range` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `min_distance` [INFO] [stdout] --> src/particle_swarm_20.rs:28:21 [INFO] [stdout] | [INFO] [stdout] 28 | let (min_index, min_distance) = particles [INFO] [stdout] | ^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_min_distance` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `key` [INFO] [stdout] --> src/particle_swarm_20.rs:48:10 [INFO] [stdout] | [INFO] [stdout] 48 | for (key, val) in occupied_points.iter() { [INFO] [stdout] | ^^^ help: if this is intentional, prefix it with an underscore: `_key` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/recursive_circus_7.rs:68:13 [INFO] [stdout] | [INFO] [stdout] 68 | let mut captured_groups = regex_pattern [INFO] [stdout] | ----^^^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/sporifica_virus_22.rs:102:10 [INFO] [stdout] | [INFO] [stdout] 102 | for (i, l) in buffered.iter().enumerate() { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `j` [INFO] [stdout] --> src/sporifica_virus_22.rs:103:14 [INFO] [stdout] | [INFO] [stdout] 103 | for (j, ch) in l.chars().enumerate() { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_j` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/stream_processing_9.rs:5:9 [INFO] [stdout] | [INFO] [stdout] 5 | let mut letters = stream.chars().collect::>(); [INFO] [stdout] | ----^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/tubes_19.rs:32:9 [INFO] [stdout] | [INFO] [stdout] 32 | let mut cur_x = 0; [INFO] [stdout] | ----^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `seen_vec` [INFO] [stdout] --> src/tubes_19.rs:31:9 [INFO] [stdout] | [INFO] [stdout] 31 | let seen_vec: Vec = Vec::new(); [INFO] [stdout] | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_seen_vec` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `inverse_captcha` is never used [INFO] [stdout] --> src/inverse_captcha_1.rs:1:4 [INFO] [stdout] | [INFO] [stdout] 1 | fn inverse_captcha(input: Vec) -> u32 { [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 `inverse_captcha2` is never used [INFO] [stdout] --> src/inverse_captcha_1.rs:13:4 [INFO] [stdout] | [INFO] [stdout] 13 | fn inverse_captcha2(input: Vec) -> u32 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `run_program` is never used [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:6:4 [INFO] [stdout] | [INFO] [stdout] 6 | fn run_program(instruction_vec: Vec) -> isize { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Instruction` is never constructed [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:78:8 [INFO] [stdout] | [INFO] [stdout] 78 | struct Instruction { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Field` is never used [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:85:6 [INFO] [stdout] | [INFO] [stdout] 85 | enum Field { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `parse_input` is never used [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:90:4 [INFO] [stdout] | [INFO] [stdout] 90 | fn parse_input(path: &str) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `test_submission_part1` is never used [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:123:8 [INFO] [stdout] | [INFO] [stdout] 123 | pub fn test_submission_part1() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_checksum` is never used [INFO] [stdout] --> src/corruption_checksum_2.rs:4:4 [INFO] [stdout] | [INFO] [stdout] 4 | fn find_checksum() -> u32 { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_checksum2` is never used [INFO] [stdout] --> src/corruption_checksum_2.rs:22:4 [INFO] [stdout] | [INFO] [stdout] 22 | fn find_checksum2() -> u32 { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bfs` is never used [INFO] [stdout] --> src/digital_plumber_12.rs:6:4 [INFO] [stdout] | [INFO] [stdout] 6 | fn bfs( [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bfs_alt` is never used [INFO] [stdout] --> src/digital_plumber_12.rs:29:4 [INFO] [stdout] | [INFO] [stdout] 29 | fn bfs_alt(adjacency_map: HashMap>) -> u16 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `part1` is never used [INFO] [stdout] --> src/digital_plumber_12.rs:59:4 [INFO] [stdout] | [INFO] [stdout] 59 | fn part1(adjacency_map: HashMap>) -> u16 { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `part2` is never used [INFO] [stdout] --> src/digital_plumber_12.rs:65:4 [INFO] [stdout] | [INFO] [stdout] 65 | fn part2(adjacency_map: HashMap>) -> u16 { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `read_input` is never used [INFO] [stdout] --> src/digital_plumber_12.rs:69:4 [INFO] [stdout] | [INFO] [stdout] 69 | fn read_input(path: &str) -> HashMap> { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `GEN1_STARTER_SAMPLE` is never used [INFO] [stdout] --> src/dueling_generators_15.rs:1:7 [INFO] [stdout] | [INFO] [stdout] 1 | const GEN1_STARTER_SAMPLE: usize = 65; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `GEN2_STARTER_SAMPLE` is never used [INFO] [stdout] --> src/dueling_generators_15.rs:2:7 [INFO] [stdout] | [INFO] [stdout] 2 | const GEN2_STARTER_SAMPLE: usize = 8921; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `GEN1_STARTER` is never used [INFO] [stdout] --> src/dueling_generators_15.rs:3:7 [INFO] [stdout] | [INFO] [stdout] 3 | const GEN1_STARTER: usize = 679; [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `GEN2_STARTER` is never used [INFO] [stdout] --> src/dueling_generators_15.rs:4:7 [INFO] [stdout] | [INFO] [stdout] 4 | const GEN2_STARTER: usize = 771; [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `GEN1_FACTOR` is never used [INFO] [stdout] --> src/dueling_generators_15.rs:5:7 [INFO] [stdout] | [INFO] [stdout] 5 | const GEN1_FACTOR: usize = 16807; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `GEN2_FACTOR` is never used [INFO] [stdout] --> src/dueling_generators_15.rs:6:7 [INFO] [stdout] | [INFO] [stdout] 6 | const GEN2_FACTOR: usize = 48271; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `part1` is never used [INFO] [stdout] --> src/dueling_generators_15.rs:8:8 [INFO] [stdout] | [INFO] [stdout] 8 | pub fn part1() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `part2` is never used [INFO] [stdout] --> src/dueling_generators_15.rs:23:8 [INFO] [stdout] | [INFO] [stdout] 23 | pub fn part2() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `gen_logic` is never used [INFO] [stdout] --> src/dueling_generators_15.rs:38:4 [INFO] [stdout] | [INFO] [stdout] 38 | fn gen_logic(multiple_factor: usize, starter: usize, factor: usize) -> usize { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `run_program` is never used [INFO] [stdout] --> src/duet_18.rs:6:4 [INFO] [stdout] | [INFO] [stdout] 6 | fn run_program(instruction_vec: Vec) -> isize { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Instruction` is never constructed [INFO] [stdout] --> src/duet_18.rs:74:8 [INFO] [stdout] | [INFO] [stdout] 74 | struct Instruction { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Field` is never used [INFO] [stdout] --> src/duet_18.rs:81:6 [INFO] [stdout] | [INFO] [stdout] 81 | enum Field { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `parse_input` is never used [INFO] [stdout] --> src/duet_18.rs:86:4 [INFO] [stdout] | [INFO] [stdout] 86 | fn parse_input(path: &str) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `extend` is never used [INFO] [stdout] --> src/electromagnetic_moat_24.rs:8:4 [INFO] [stdout] | [INFO] [stdout] 8 | fn extend( [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `main` is never used [INFO] [stdout] --> src/electromagnetic_moat_24.rs:32:8 [INFO] [stdout] | [INFO] [stdout] 32 | pub fn main() {} [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `tm1_sample` is never used [INFO] [stdout] --> src/halting_problem_25.rs:3:4 [INFO] [stdout] | [INFO] [stdout] 3 | fn tm1_sample(count: isize) -> usize { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `tm1_submission` is never used [INFO] [stdout] --> src/halting_problem_25.rs:53:4 [INFO] [stdout] | [INFO] [stdout] 53 | fn tm1_submission(count: isize) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_distance` is never used [INFO] [stdout] --> src/hex_ed_11.rs:13:4 [INFO] [stdout] | [INFO] [stdout] 13 | fn find_distance(input: Vec<&str>) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hex_dist` is never used [INFO] [stdout] --> src/hex_ed_11.rs:56:4 [INFO] [stdout] | [INFO] [stdout] 56 | fn hex_dist(current_position: (isize, isize, isize)) -> usize { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `is_valid` is never used [INFO] [stdout] --> src/high_entropy_passphrase_4.rs:3:4 [INFO] [stdout] | [INFO] [stdout] 3 | fn is_valid(passphrase: String) -> bool { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `is_valid_advanced` is never used [INFO] [stdout] --> src/high_entropy_passphrase_4.rs:15:4 [INFO] [stdout] | [INFO] [stdout] 15 | fn is_valid_advanced(passphrase: String) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `solve_part_1` is never used [INFO] [stdout] --> src/maze_5.rs:4:4 [INFO] [stdout] | [INFO] [stdout] 4 | fn solve_part_1(mut list: Vec) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `solve_part_2` is never used [INFO] [stdout] --> src/maze_5.rs:19:4 [INFO] [stdout] | [INFO] [stdout] 19 | fn solve_part_2(mut list: Vec) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `read_input` is never used [INFO] [stdout] --> src/maze_5.rs:37:4 [INFO] [stdout] | [INFO] [stdout] 37 | fn read_input() -> Vec { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `solve_p1` is never used [INFO] [stdout] --> src/memory_realloc_6.rs:5:4 [INFO] [stdout] | [INFO] [stdout] 5 | fn solve_p1(mut banks: Vec) -> (usize, usize) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `part1` is never used [INFO] [stdout] --> src/packet_scanners_13.rs:5:4 [INFO] [stdout] | [INFO] [stdout] 5 | fn part1(scanners: Vec<(u16, u16)>) -> u16 { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `part2` is never used [INFO] [stdout] --> src/packet_scanners_13.rs:53:4 [INFO] [stdout] | [INFO] [stdout] 53 | fn part2() {} [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `read_input` is never used [INFO] [stdout] --> src/packet_scanners_13.rs:55:4 [INFO] [stdout] | [INFO] [stdout] 55 | fn read_input(path: &str) -> Vec<(u16, u16)> { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Point3D` is never constructed [INFO] [stdout] --> src/particle_swarm_20.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | struct Point3D { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Particle` is never constructed [INFO] [stdout] --> src/particle_swarm_20.rs:11:8 [INFO] [stdout] | [INFO] [stdout] 11 | struct Particle { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `tick` is never used [INFO] [stdout] --> src/particle_swarm_20.rs:17:4 [INFO] [stdout] | [INFO] [stdout] 17 | fn tick(particle: &mut Particle) { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_closest_index` is never used [INFO] [stdout] --> src/particle_swarm_20.rs:27:4 [INFO] [stdout] | [INFO] [stdout] 27 | fn find_closest_index(particles: &Vec) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_collisions` is never used [INFO] [stdout] --> src/particle_swarm_20.rs:38:4 [INFO] [stdout] | [INFO] [stdout] 38 | fn find_collisions(particles: &mut Vec) { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `spin` is never used [INFO] [stdout] --> src/permutation_promenade_16.rs:3:4 [INFO] [stdout] | [INFO] [stdout] 3 | fn spin(shift_amount: usize, line: &mut Vec<&str>) { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `exchange` is never used [INFO] [stdout] --> src/permutation_promenade_16.rs:7:4 [INFO] [stdout] | [INFO] [stdout] 7 | fn exchange(prog1_pos: usize, prog2_pos: usize, line: &mut Vec<&str>) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `partner` is never used [INFO] [stdout] --> src/permutation_promenade_16.rs:11:4 [INFO] [stdout] | [INFO] [stdout] 11 | fn partner(prog1: &str, prog2: &str, line: &mut Vec<&str>) { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_bottom_program` is never used [INFO] [stdout] --> src/recursive_circus_7.rs:9:4 [INFO] [stdout] | [INFO] [stdout] 9 | fn find_bottom_program(program_map: HashMap)>) -> String { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `parse_input` is never used [INFO] [stdout] --> src/recursive_circus_7.rs:62:4 [INFO] [stdout] | [INFO] [stdout] 62 | fn parse_input(path: &str) -> HashMap)> { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `part1` is never used [INFO] [stdout] --> src/registers_8.rs:5:4 [INFO] [stdout] | [INFO] [stdout] 5 | fn part1(lines: Lines>) -> (i32, i32) { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `spinlock_tick` is never used [INFO] [stdout] --> src/spinlock_17.rs:1:4 [INFO] [stdout] | [INFO] [stdout] 1 | fn spinlock_tick(current_pos: usize, step: usize, buffer: &mut Vec) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `spiral_idx_to_xy` is never used [INFO] [stdout] --> src/spiral_memory_3.rs:50:4 [INFO] [stdout] | [INFO] [stdout] 50 | fn spiral_idx_to_xy(idx: usize) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: type alias `I` is never used [INFO] [stdout] --> src/spiral_memory_3.rs:66:6 [INFO] [stdout] | [INFO] [stdout] 66 | type I = i32; [INFO] [stdout] | ^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: type alias `U` is never used [INFO] [stdout] --> src/spiral_memory_3.rs:67:6 [INFO] [stdout] | [INFO] [stdout] 67 | type U = usize; [INFO] [stdout] | ^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `layer_index` is never used [INFO] [stdout] --> src/spiral_memory_3.rs:69:4 [INFO] [stdout] | [INFO] [stdout] 69 | fn layer_index(p: I) -> (I, I, I, I) { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `mod_pos` is never used [INFO] [stdout] --> src/spiral_memory_3.rs:96:8 [INFO] [stdout] | [INFO] [stdout] 96 | pub fn mod_pos(a: I, b: I) -> I { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `manhattan` is never used [INFO] [stdout] --> src/spiral_memory_3.rs:100:4 [INFO] [stdout] | [INFO] [stdout] 100 | fn manhattan(p: I) -> I { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `part2` is never used [INFO] [stdout] --> src/spiral_memory_3.rs:105:4 [INFO] [stdout] | [INFO] [stdout] 105 | fn part2(target: I) -> I { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Direction` is never used [INFO] [stdout] --> src/sporifica_virus_22.rs:7:6 [INFO] [stdout] | [INFO] [stdout] 7 | enum Direction { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Rotation` is never used [INFO] [stdout] --> src/sporifica_virus_22.rs:15:6 [INFO] [stdout] | [INFO] [stdout] 15 | enum Rotation { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Carrier` is never constructed [INFO] [stdout] --> src/sporifica_virus_22.rs:21:8 [INFO] [stdout] | [INFO] [stdout] 21 | struct Carrier { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Point2D` is never constructed [INFO] [stdout] --> src/sporifica_virus_22.rs:27:8 [INFO] [stdout] | [INFO] [stdout] 27 | struct Point2D { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `xy_diff` is never used [INFO] [stdout] --> src/sporifica_virus_22.rs:39:4 [INFO] [stdout] | [INFO] [stdout] 39 | fn xy_diff(direction: &Direction) -> Point2D { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `new_direction` is never used [INFO] [stdout] --> src/sporifica_virus_22.rs:48:4 [INFO] [stdout] | [INFO] [stdout] 48 | fn new_direction(current_direction: &Direction, rotate: Rotation) -> Direction { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `tick` is never used [INFO] [stdout] --> src/sporifica_virus_22.rs:65:4 [INFO] [stdout] | [INFO] [stdout] 65 | fn tick(carrier: &mut Carrier, grid_map: &mut HashMap, infected_count: &mut usize) { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `parse_input` is never used [INFO] [stdout] --> src/sporifica_virus_22.rs:88:4 [INFO] [stdout] | [INFO] [stdout] 88 | fn parse_input(path: &str) -> HashMap { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `solve_part1` is never used [INFO] [stdout] --> src/stream_processing_9.rs:4:4 [INFO] [stdout] | [INFO] [stdout] 4 | fn solve_part1(stream: String) -> u32 { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Point` is never constructed [INFO] [stdout] --> src/tubes_19.rs:3:8 [INFO] [stdout] | [INFO] [stdout] 3 | struct Point { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Packet` is never constructed [INFO] [stdout] --> src/tubes_19.rs:8:8 [INFO] [stdout] | [INFO] [stdout] 8 | struct Packet { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Direction` is never used [INFO] [stdout] --> src/tubes_19.rs:15:6 [INFO] [stdout] | [INFO] [stdout] 15 | enum Direction { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `follow_route` is never used [INFO] [stdout] --> src/tubes_19.rs:22:4 [INFO] [stdout] | [INFO] [stdout] 22 | fn follow_route(route_map: Vec>) -> String { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting to the same type is unnecessary (`u32` -> `u32`) [INFO] [stdout] --> src/inverse_captcha_1.rs:7:20 [INFO] [stdout] | [INFO] [stdout] 7 | sum += input[idx] as u32; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: try: `input[idx]` [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: casting to the same type is unnecessary (`u32` -> `u32`) [INFO] [stdout] --> src/inverse_captcha_1.rs:18:20 [INFO] [stdout] | [INFO] [stdout] 18 | sum += input[i] as u32; [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: try: `input[i]` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:74:5 [INFO] [stdout] | [INFO] [stdout] 74 | return mul_count; [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] 74 - return mul_count; [INFO] [stdout] 74 + mul_count [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: usage of `contains_key` followed by `insert` on a `HashMap` [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:19:13 [INFO] [stdout] | [INFO] [stdout] 19 | / if !register_map.contains_key(&c) { [INFO] [stdout] 20 | | register_map.insert(c, 0); [INFO] [stdout] 21 | | } [INFO] [stdout] | |_____________^ help: try: `register_map.entry(c).or_insert(0);` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_entry [INFO] [stdout] = note: `#[warn(clippy::map_entry)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `.is_multiple_of()` [INFO] [stdout] --> src/corruption_checksum_2.rs:38:34 [INFO] [stdout] | [INFO] [stdout] 38 | if i != j && list[i] % list[j] == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `list[i].is_multiple_of(list[j])` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_is_multiple_of [INFO] [stdout] = note: `#[warn(clippy::manual_is_multiple_of)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/digital_plumber_12.rs:26:5 [INFO] [stdout] | [INFO] [stdout] 26 | return visited_node_count; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 26 - return visited_node_count; [INFO] [stdout] 26 + visited_node_count [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you seem to be trying to pop elements from a `Vec` in a loop [INFO] [stdout] --> src/digital_plumber_12.rs:15:9 [INFO] [stdout] | [INFO] [stdout] 15 | let node = stack.pop().unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_while_let_some [INFO] [stdout] = note: `#[warn(clippy::manual_while_let_some)]` on by default [INFO] [stdout] help: consider using a `while..let` loop [INFO] [stdout] | [INFO] [stdout] 14 ~ while let Some(node) = stack.pop() { [INFO] [stdout] 15 ~ [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/digital_plumber_12.rs:21:28 [INFO] [stdout] | [INFO] [stdout] 21 | stack.push(n.clone()); [INFO] [stdout] | ^^^^^^^^^ help: try dereferencing it: `*n` [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: unneeded `return` statement [INFO] [stdout] --> src/digital_plumber_12.rs:56:5 [INFO] [stdout] | [INFO] [stdout] 56 | return num_groups; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 56 - return num_groups; [INFO] [stdout] 56 + num_groups [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/digital_plumber_12.rs:38:30 [INFO] [stdout] | [INFO] [stdout] 38 | start_node = node.clone(); [INFO] [stdout] | ^^^^^^^^^^^^ help: try dereferencing it: `*node` [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: you seem to be trying to pop elements from a `Vec` in a loop [INFO] [stdout] --> src/digital_plumber_12.rs:44:13 [INFO] [stdout] | [INFO] [stdout] 44 | let node = stack.pop().unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_while_let_some [INFO] [stdout] help: consider using a `while..let` loop [INFO] [stdout] | [INFO] [stdout] 43 ~ while let Some(node) = stack.pop() { [INFO] [stdout] 44 ~ [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/digital_plumber_12.rs:49:32 [INFO] [stdout] | [INFO] [stdout] 49 | stack.push(n.clone()); [INFO] [stdout] | ^^^^^^^^^ help: try dereferencing it: `*n` [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: unneeded `return` statement [INFO] [stdout] --> src/digital_plumber_12.rs:62:5 [INFO] [stdout] | [INFO] [stdout] 62 | return cnt; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 62 - return cnt; [INFO] [stdout] 62 + cnt [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/digital_plumber_12.rs:66:5 [INFO] [stdout] | [INFO] [stdout] 66 | return bfs_alt(adjacency_map); [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 66 - return bfs_alt(adjacency_map); [INFO] [stdout] 66 + bfs_alt(adjacency_map) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/digital_plumber_12.rs:89:5 [INFO] [stdout] | [INFO] [stdout] 89 | return adjacency_map; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 89 - return adjacency_map; [INFO] [stdout] 89 + adjacency_map [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: usage of `contains_key` followed by `insert` on a `HashMap` [INFO] [stdout] --> src/digital_plumber_12.rs:82:9 [INFO] [stdout] | [INFO] [stdout] 82 | / if adjacency_map.contains_key(&node) { [INFO] [stdout] 83 | | adjacency_map.get(&node).unwrap().union(&neighbors); [INFO] [stdout] 84 | | } else { [INFO] [stdout] 85 | | adjacency_map.insert(node, neighbors); [INFO] [stdout] 86 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_entry [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 82 ~ if let std::collections::hash_map::Entry::Vacant(e) = adjacency_map.entry(node) { [INFO] [stdout] 83 + e.insert(neighbors); [INFO] [stdout] 84 + } else { [INFO] [stdout] 85 + adjacency_map.get(&node).unwrap().union(&neighbors); [INFO] [stdout] 86 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/dueling_generators_15.rs:43:5 [INFO] [stdout] | [INFO] [stdout] 43 | return prev; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 43 - return prev; [INFO] [stdout] 43 + prev [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/duet_18.rs:70:5 [INFO] [stdout] | [INFO] [stdout] 70 | return last_played; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 70 - return last_played; [INFO] [stdout] 70 + last_played [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: usage of `contains_key` followed by `insert` on a `HashMap` [INFO] [stdout] --> src/duet_18.rs:20:9 [INFO] [stdout] | [INFO] [stdout] 20 | / if !register_map.contains_key(&target_register) { [INFO] [stdout] 21 | | register_map.insert(target_register, 0); [INFO] [stdout] 22 | | } [INFO] [stdout] | |_________^ help: try: `register_map.entry(target_register).or_insert(0);` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_entry [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: equality checks against true are unnecessary [INFO] [stdout] --> src/halting_problem_25.rs:50:28 [INFO] [stdout] | [INFO] [stdout] 50 | tape.iter().filter(|x| **x == true).count() [INFO] [stdout] | ^^^^^^^^^^^ help: try: `**x` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_comparison [INFO] [stdout] = note: `#[warn(clippy::bool_comparison)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: equality checks against true are unnecessary [INFO] [stdout] --> src/halting_problem_25.rs:175:28 [INFO] [stdout] | [INFO] [stdout] 175 | tape.iter().filter(|x| **x == true).count() [INFO] [stdout] | ^^^^^^^^^^^ help: try: `**x` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_comparison [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/packet_scanners_13.rs:50:5 [INFO] [stdout] | [INFO] [stdout] 50 | return severity; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 50 - return severity; [INFO] [stdout] 50 + severity [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/packet_scanners_13.rs:8:28 [INFO] [stdout] | [INFO] [stdout] 8 | scanner_pos.insert(depth.clone(), 0); [INFO] [stdout] | ^^^^^^^^^^^^^ help: try dereferencing it: `*depth` [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: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/packet_scanners_13.rs:12:29 [INFO] [stdout] | [INFO] [stdout] 12 | scanner_flag.insert(depth.clone(), false); [INFO] [stdout] | ^^^^^^^^^^^^^ help: try dereferencing it: `*depth` [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: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/packet_scanners_13.rs:16:20 [INFO] [stdout] | [INFO] [stdout] 16 | scn.insert(k.clone(), v.clone()); [INFO] [stdout] | ^^^^^^^^^ help: try dereferencing it: `*k` [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: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/packet_scanners_13.rs:16:31 [INFO] [stdout] | [INFO] [stdout] 16 | scn.insert(k.clone(), v.clone()); [INFO] [stdout] | ^^^^^^^^^ help: try dereferencing it: `*v` [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 `if` statement can be collapsed [INFO] [stdout] --> src/packet_scanners_13.rs:25:9 [INFO] [stdout] | [INFO] [stdout] 25 | / if scanner_pos.contains_key(¤t_depth) { [INFO] [stdout] 26 | | if *scanner_pos.get(¤t_depth).unwrap() == 0 { [INFO] [stdout] 27 | | severity += current_depth * scn.get(¤t_depth).unwrap() [INFO] [stdout] 28 | | } [INFO] [stdout] 29 | | } [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] 25 ~ if scanner_pos.contains_key(¤t_depth) [INFO] [stdout] 26 ~ && *scanner_pos.get(¤t_depth).unwrap() == 0 { [INFO] [stdout] 27 | severity += current_depth * scn.get(¤t_depth).unwrap() [INFO] [stdout] 28 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/packet_scanners_13.rs:31:48 [INFO] [stdout] | [INFO] [stdout] 31 | if *scanner_pos.get(k).unwrap() == scn.get(k).unwrap().clone() - 1 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try dereferencing it: `*scn.get(k).unwrap()` [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 `if` statement can be collapsed [INFO] [stdout] --> src/packet_scanners_13.rs:35:20 [INFO] [stdout] | [INFO] [stdout] 35 | } else if *scanner_pos.get(k).unwrap() == 0 { [INFO] [stdout] | ____________________^ [INFO] [stdout] 36 | | if scanner_flag.get(k).unwrap() == &true { [INFO] [stdout] 37 | | *scanner_flag.get_mut(k).unwrap() = false; [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 ~ } else if *scanner_pos.get(k).unwrap() == 0 [INFO] [stdout] 36 ~ && scanner_flag.get(k).unwrap() == &true { [INFO] [stdout] 37 | *scanner_flag.get_mut(k).unwrap() = false; [INFO] [stdout] 38 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/packet_scanners_13.rs:64:5 [INFO] [stdout] | [INFO] [stdout] 64 | return scanners; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 64 - return scanners; [INFO] [stdout] 64 + scanners [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/particle_swarm_20.rs:27:34 [INFO] [stdout] | [INFO] [stdout] 27 | fn find_closest_index(particles: &Vec) -> 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] = note: `#[warn(clippy::ptr_arg)]` on by default [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 27 - fn find_closest_index(particles: &Vec) -> usize { [INFO] [stdout] 27 + fn find_closest_index(particles: &[Particle]) -> usize { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `filter(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find(..)` instead [INFO] [stdout] --> src/recursive_circus_7.rs:18:5 [INFO] [stdout] | [INFO] [stdout] 18 | / program_map.keys() [INFO] [stdout] 19 | | .filter(|x| !parent_map.contains_key(x.as_str())) [INFO] [stdout] 20 | | .next() [INFO] [stdout] | |_______________^ help: try: `program_map.keys().find(|x| !parent_map.contains_key(x.as_str()))` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#filter_next [INFO] [stdout] = note: `#[warn(clippy::filter_next)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/registers_8.rs:23:20 [INFO] [stdout] | [INFO] [stdout] 23 | if !(registers[&condition_register] > condition_val) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(registers[&condition_register] <= condition_val)` [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] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/registers_8.rs:28:20 [INFO] [stdout] | [INFO] [stdout] 28 | if !(registers[&condition_register] < condition_val) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(registers[&condition_register] >= condition_val)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/registers_8.rs:33:20 [INFO] [stdout] | [INFO] [stdout] 33 | if !(registers[&condition_register] == condition_val) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(registers[&condition_register] != condition_val)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/registers_8.rs:38:20 [INFO] [stdout] | [INFO] [stdout] 38 | if !(registers[&condition_register] >= condition_val) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(registers[&condition_register] < condition_val)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/registers_8.rs:43:20 [INFO] [stdout] | [INFO] [stdout] 43 | if !(registers[&condition_register] <= condition_val) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(registers[&condition_register] > condition_val)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/registers_8.rs:48:20 [INFO] [stdout] | [INFO] [stdout] 48 | if !(registers[&condition_register] != condition_val) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(registers[&condition_register] == condition_val)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/spinlock_17.rs:5:5 [INFO] [stdout] | [INFO] [stdout] 5 | return next_pos; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 5 - return next_pos; [INFO] [stdout] 5 + next_pos [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting to the same type is unnecessary (`usize` -> `usize`) [INFO] [stdout] --> src/spiral_memory_3.rs:59:5 [INFO] [stdout] | [INFO] [stdout] 59 | (layer + dist2 as usize) as usize [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(layer + dist2 as usize)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this multiplication by -1 can be written more succinctly [INFO] [stdout] --> src/sporifica_virus_22.rs:101:19 [INFO] [stdout] | [INFO] [stdout] 101 | let mut yid = -1 * dim / 2; [INFO] [stdout] | ^^^^^^^^ help: consider using: `-dim` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#neg_multiply [INFO] [stdout] = note: `#[warn(clippy::neg_multiply)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `i` is used to index `route_map` [INFO] [stdout] --> src/tubes_19.rs:35:14 [INFO] [stdout] | [INFO] [stdout] 35 | for i in 0..route_map[0].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 and enumerate() [INFO] [stdout] | [INFO] [stdout] 35 - for i in 0..route_map[0].len() { [INFO] [stdout] 35 + for (i, ) in route_map.iter().enumerate().take(route_map[0].len()) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/tubes_19.rs:61:13 [INFO] [stdout] | [INFO] [stdout] 61 | / if (packet.loc.x as usize + 1) < route_map.len() [INFO] [stdout] 62 | | && route_map[packet.loc.x as usize + 1][packet.loc.y as usize] != ' ' [INFO] [stdout] 63 | | { [INFO] [stdout] 64 | | if packet.direction != Direction::Up { [INFO] [stdout] ... | [INFO] [stdout] 67 | | } [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] 62 ~ && route_map[packet.loc.x as usize + 1][packet.loc.y as usize] != ' ' [INFO] [stdout] 63 ~ && packet.direction != Direction::Up { [INFO] [stdout] 64 | new_dir = Direction::Down; [INFO] [stdout] 65 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/tubes_19.rs:68:13 [INFO] [stdout] | [INFO] [stdout] 68 | / if (packet.loc.x - 1) >= 0 [INFO] [stdout] 69 | | && route_map[packet.loc.x as usize - 1][packet.loc.y as usize] != ' ' [INFO] [stdout] 70 | | { [INFO] [stdout] 71 | | if packet.direction != Direction::Down { [INFO] [stdout] ... | [INFO] [stdout] 74 | | } [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] 69 ~ && route_map[packet.loc.x as usize - 1][packet.loc.y as usize] != ' ' [INFO] [stdout] 70 ~ && packet.direction != Direction::Down { [INFO] [stdout] 71 | new_dir = Direction::Up; [INFO] [stdout] 72 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/tubes_19.rs:75:13 [INFO] [stdout] | [INFO] [stdout] 75 | / if (packet.loc.y as usize + 1) < route_map[packet.loc.x as usize].len() [INFO] [stdout] 76 | | && route_map[packet.loc.x as usize][packet.loc.y as usize + 1] != ' ' [INFO] [stdout] 77 | | { [INFO] [stdout] 78 | | if packet.direction != Direction::Left { [INFO] [stdout] ... | [INFO] [stdout] 81 | | } [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] 76 ~ && route_map[packet.loc.x as usize][packet.loc.y as usize + 1] != ' ' [INFO] [stdout] 77 ~ && packet.direction != Direction::Left { [INFO] [stdout] 78 | new_dir = Direction::Right; [INFO] [stdout] 79 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/tubes_19.rs:82:13 [INFO] [stdout] | [INFO] [stdout] 82 | / if (packet.loc.y - 1) >= 0 [INFO] [stdout] 83 | | && route_map[packet.loc.x as usize][packet.loc.y as usize - 1] != ' ' [INFO] [stdout] 84 | | { [INFO] [stdout] 85 | | if packet.direction != Direction::Right { [INFO] [stdout] ... | [INFO] [stdout] 88 | | } [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] 83 ~ && route_map[packet.loc.x as usize][packet.loc.y as usize - 1] != ' ' [INFO] [stdout] 84 ~ && packet.direction != Direction::Right { [INFO] [stdout] 85 | new_dir = Direction::Left; [INFO] [stdout] 86 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused `std::collections::hash_set::Union` that must be used [INFO] [stdout] --> src/digital_plumber_12.rs:83:13 [INFO] [stdout] | [INFO] [stdout] 83 | adjacency_map.get(&node).unwrap().union(&neighbors); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: this returns the union as an iterator, without modifying either input set [INFO] [stdout] = note: `#[warn(unused_must_use)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: use `let _ = ...` to ignore the resulting value [INFO] [stdout] | [INFO] [stdout] 83 | let _ = adjacency_map.get(&node).unwrap().union(&neighbors); [INFO] [stdout] | +++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:15:13 [INFO] [stdout] | [INFO] [stdout] 15 | let mut lc = line_cursor as usize; [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: unused variable: `lc` [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:15:13 [INFO] [stdout] | [INFO] [stdout] 15 | let mut lc = line_cursor as usize; [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_lc` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `c` [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:54:33 [INFO] [stdout] | [INFO] [stdout] 54 | Field::Register(c) => { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_c` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/digital_plumber_12.rs:75:13 [INFO] [stdout] | [INFO] [stdout] 75 | let mut split_line: Vec<&str> = line.split(" <-> ").collect(); [INFO] [stdout] | ----^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/dueling_generators_15.rs:12:9 [INFO] [stdout] | [INFO] [stdout] 12 | for i in 0..(40 * 10_usize.pow(6)) { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/dueling_generators_15.rs:27:9 [INFO] [stdout] | [INFO] [stdout] 27 | for i in 0..(5 * 10_usize.pow(6)) { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/dueling_generators_15.rs:55:13 [INFO] [stdout] | [INFO] [stdout] 55 | for i in 0..5 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/duet_18.rs:11:13 [INFO] [stdout] | [INFO] [stdout] 11 | let mut lc = line_cursor as usize; [INFO] [stdout] | ----^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `lc` [INFO] [stdout] --> src/duet_18.rs:11:13 [INFO] [stdout] | [INFO] [stdout] 11 | let mut lc = line_cursor as usize; [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_lc` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `last_sound` [INFO] [stdout] --> src/duet_18.rs:142:13 [INFO] [stdout] | [INFO] [stdout] 142 | let last_sound = run_program(instruction_vec); [INFO] [stdout] | ^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_last_sound` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/halting_problem_25.rs:9:9 [INFO] [stdout] | [INFO] [stdout] 9 | for i in 0..count { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/halting_problem_25.rs:59:9 [INFO] [stdout] | [INFO] [stdout] 59 | for i in 0..count { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/high_entropy_passphrase_4.rs:61:17 [INFO] [stdout] | [INFO] [stdout] 61 | let mut l = line.unwrap(); [INFO] [stdout] | ----^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/high_entropy_passphrase_4.rs:109:17 [INFO] [stdout] | [INFO] [stdout] 109 | let mut l = line.unwrap(); [INFO] [stdout] | ----^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/memory_realloc_6.rs:11:23 [INFO] [stdout] | [INFO] [stdout] 11 | let (mut mid, mut mval) = banks [INFO] [stdout] | ----^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/memory_realloc_6.rs:24:13 [INFO] [stdout] | [INFO] [stdout] 24 | for i in 0..blocks { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `banks` [INFO] [stdout] --> src/memory_realloc_6.rs:39:13 [INFO] [stdout] | [INFO] [stdout] 39 | let banks = vec![0, 2, 7, 0]; [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_banks` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/memory_realloc_6.rs:46:13 [INFO] [stdout] | [INFO] [stdout] 46 | let mut buffered = BufReader::new(file); [INFO] [stdout] | ----^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `range` [INFO] [stdout] --> src/packet_scanners_13.rs:7:17 [INFO] [stdout] | [INFO] [stdout] 7 | for (depth, range) in scanners.iter() { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_range` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `range` [INFO] [stdout] --> src/packet_scanners_13.rs:11:17 [INFO] [stdout] | [INFO] [stdout] 11 | for (depth, range) in scanners.iter() { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_range` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `min_distance` [INFO] [stdout] --> src/particle_swarm_20.rs:28:21 [INFO] [stdout] | [INFO] [stdout] 28 | let (min_index, min_distance) = particles [INFO] [stdout] | ^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_min_distance` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `key` [INFO] [stdout] --> src/particle_swarm_20.rs:48:10 [INFO] [stdout] | [INFO] [stdout] 48 | for (key, val) in occupied_points.iter() { [INFO] [stdout] | ^^^ help: if this is intentional, prefix it with an underscore: `_key` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/particle_swarm_20.rs:71:17 [INFO] [stdout] | [INFO] [stdout] 71 | let mut triple = &mut ln_str.split(", "); [INFO] [stdout] | ----^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/particle_swarm_20.rs:73:17 [INFO] [stdout] | [INFO] [stdout] 73 | for i in 0..3 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/particle_swarm_20.rs:98:13 [INFO] [stdout] | [INFO] [stdout] 98 | for i in 0..ticks_count { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/particle_swarm_20.rs:111:13 [INFO] [stdout] | [INFO] [stdout] 111 | for i in 0..ticks_count { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/particle_swarm_20.rs:124:13 [INFO] [stdout] | [INFO] [stdout] 124 | for i in 0..ticks_count { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/particle_swarm_20.rs:138:13 [INFO] [stdout] | [INFO] [stdout] 138 | for i in 0..ticks_count { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/recursive_circus_7.rs:68:13 [INFO] [stdout] | [INFO] [stdout] 68 | let mut captured_groups = regex_pattern [INFO] [stdout] | ----^^^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `root` [INFO] [stdout] --> src/recursive_circus_7.rs:114:13 [INFO] [stdout] | [INFO] [stdout] 114 | let root = find_bottom_program(program_map); [INFO] [stdout] | ^^^^ help: if this is intentional, prefix it with an underscore: `_root` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/spinlock_17.rs:25:13 [INFO] [stdout] | [INFO] [stdout] 25 | for i in 0..(2017 - 2) { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/spinlock_17.rs:37:13 [INFO] [stdout] | [INFO] [stdout] 37 | for i in 0..2017 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/spinlock_17.rs:77:21 [INFO] [stdout] | [INFO] [stdout] 77 | let mut ind = *(index_map.get(&prev).unwrap()); [INFO] [stdout] | ----^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/sporifica_virus_22.rs:102:10 [INFO] [stdout] | [INFO] [stdout] 102 | for (i, l) in buffered.iter().enumerate() { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `j` [INFO] [stdout] --> src/sporifica_virus_22.rs:103:14 [INFO] [stdout] | [INFO] [stdout] 103 | for (j, ch) in l.chars().enumerate() { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_j` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/sporifica_virus_22.rs:135:13 [INFO] [stdout] | [INFO] [stdout] 135 | for i in 0..burst_count { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `i` [INFO] [stdout] --> src/sporifica_virus_22.rs:151:13 [INFO] [stdout] | [INFO] [stdout] 151 | for i in 0..burst_count { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_i` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/stream_processing_9.rs:5:9 [INFO] [stdout] | [INFO] [stdout] 5 | let mut letters = stream.chars().collect::>(); [INFO] [stdout] | ----^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/tubes_19.rs:32:9 [INFO] [stdout] | [INFO] [stdout] 32 | let mut cur_x = 0; [INFO] [stdout] | ----^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `seen_vec` [INFO] [stdout] --> src/tubes_19.rs:31:9 [INFO] [stdout] | [INFO] [stdout] 31 | let seen_vec: Vec = Vec::new(); [INFO] [stdout] | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_seen_vec` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `test_submission_part1` is never used [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:123:8 [INFO] [stdout] | [INFO] [stdout] 123 | pub fn test_submission_part1() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `GEN1_STARTER` is never used [INFO] [stdout] --> src/dueling_generators_15.rs:3:7 [INFO] [stdout] | [INFO] [stdout] 3 | const GEN1_STARTER: usize = 679; [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `GEN2_STARTER` is never used [INFO] [stdout] --> src/dueling_generators_15.rs:4:7 [INFO] [stdout] | [INFO] [stdout] 4 | const GEN2_STARTER: usize = 771; [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `part1` is never used [INFO] [stdout] --> src/dueling_generators_15.rs:8:8 [INFO] [stdout] | [INFO] [stdout] 8 | pub fn part1() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `part2` is never used [INFO] [stdout] --> src/dueling_generators_15.rs:23:8 [INFO] [stdout] | [INFO] [stdout] 23 | pub fn part2() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `gen_logic` is never used [INFO] [stdout] --> src/dueling_generators_15.rs:38:4 [INFO] [stdout] | [INFO] [stdout] 38 | fn gen_logic(multiple_factor: usize, starter: usize, factor: usize) -> usize { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `extend` is never used [INFO] [stdout] --> src/electromagnetic_moat_24.rs:8:4 [INFO] [stdout] | [INFO] [stdout] 8 | fn extend( [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `main` is never used [INFO] [stdout] --> src/electromagnetic_moat_24.rs:32:8 [INFO] [stdout] | [INFO] [stdout] 32 | pub fn main() {} [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `part2` is never used [INFO] [stdout] --> src/packet_scanners_13.rs:53:4 [INFO] [stdout] | [INFO] [stdout] 53 | fn part2() {} [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `manhattan` is never used [INFO] [stdout] --> src/spiral_memory_3.rs:100:4 [INFO] [stdout] | [INFO] [stdout] 100 | fn manhattan(p: I) -> I { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting to the same type is unnecessary (`u32` -> `u32`) [INFO] [stdout] --> src/inverse_captcha_1.rs:7:20 [INFO] [stdout] | [INFO] [stdout] 7 | sum += input[idx] as u32; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: try: `input[idx]` [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: casting to the same type is unnecessary (`u32` -> `u32`) [INFO] [stdout] --> src/inverse_captcha_1.rs:18:20 [INFO] [stdout] | [INFO] [stdout] 18 | sum += input[i] as u32; [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: try: `input[i]` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:74:5 [INFO] [stdout] | [INFO] [stdout] 74 | return mul_count; [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] 74 - return mul_count; [INFO] [stdout] 74 + mul_count [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: usage of `contains_key` followed by `insert` on a `HashMap` [INFO] [stdout] --> src/coprocessor_conflagration_23.rs:19:13 [INFO] [stdout] | [INFO] [stdout] 19 | / if !register_map.contains_key(&c) { [INFO] [stdout] 20 | | register_map.insert(c, 0); [INFO] [stdout] 21 | | } [INFO] [stdout] | |_____________^ help: try: `register_map.entry(c).or_insert(0);` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_entry [INFO] [stdout] = note: `#[warn(clippy::map_entry)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `.is_multiple_of()` [INFO] [stdout] --> src/corruption_checksum_2.rs:38:34 [INFO] [stdout] | [INFO] [stdout] 38 | if i != j && list[i] % list[j] == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `list[i].is_multiple_of(list[j])` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_is_multiple_of [INFO] [stdout] = note: `#[warn(clippy::manual_is_multiple_of)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/digital_plumber_12.rs:26:5 [INFO] [stdout] | [INFO] [stdout] 26 | return visited_node_count; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 26 - return visited_node_count; [INFO] [stdout] 26 + visited_node_count [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you seem to be trying to pop elements from a `Vec` in a loop [INFO] [stdout] --> src/digital_plumber_12.rs:15:9 [INFO] [stdout] | [INFO] [stdout] 15 | let node = stack.pop().unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_while_let_some [INFO] [stdout] = note: `#[warn(clippy::manual_while_let_some)]` on by default [INFO] [stdout] help: consider using a `while..let` loop [INFO] [stdout] | [INFO] [stdout] 14 ~ while let Some(node) = stack.pop() { [INFO] [stdout] 15 ~ [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/digital_plumber_12.rs:21:28 [INFO] [stdout] | [INFO] [stdout] 21 | stack.push(n.clone()); [INFO] [stdout] | ^^^^^^^^^ help: try dereferencing it: `*n` [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: unneeded `return` statement [INFO] [stdout] --> src/digital_plumber_12.rs:56:5 [INFO] [stdout] | [INFO] [stdout] 56 | return num_groups; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 56 - return num_groups; [INFO] [stdout] 56 + num_groups [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/digital_plumber_12.rs:38:30 [INFO] [stdout] | [INFO] [stdout] 38 | start_node = node.clone(); [INFO] [stdout] | ^^^^^^^^^^^^ help: try dereferencing it: `*node` [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: you seem to be trying to pop elements from a `Vec` in a loop [INFO] [stdout] --> src/digital_plumber_12.rs:44:13 [INFO] [stdout] | [INFO] [stdout] 44 | let node = stack.pop().unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_while_let_some [INFO] [stdout] help: consider using a `while..let` loop [INFO] [stdout] | [INFO] [stdout] 43 ~ while let Some(node) = stack.pop() { [INFO] [stdout] 44 ~ [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/digital_plumber_12.rs:49:32 [INFO] [stdout] | [INFO] [stdout] 49 | stack.push(n.clone()); [INFO] [stdout] | ^^^^^^^^^ help: try dereferencing it: `*n` [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: unneeded `return` statement [INFO] [stdout] --> src/digital_plumber_12.rs:62:5 [INFO] [stdout] | [INFO] [stdout] 62 | return cnt; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 62 - return cnt; [INFO] [stdout] 62 + cnt [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/digital_plumber_12.rs:66:5 [INFO] [stdout] | [INFO] [stdout] 66 | return bfs_alt(adjacency_map); [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 66 - return bfs_alt(adjacency_map); [INFO] [stdout] 66 + bfs_alt(adjacency_map) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/digital_plumber_12.rs:89:5 [INFO] [stdout] | [INFO] [stdout] 89 | return adjacency_map; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 89 - return adjacency_map; [INFO] [stdout] 89 + adjacency_map [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: usage of `contains_key` followed by `insert` on a `HashMap` [INFO] [stdout] --> src/digital_plumber_12.rs:82:9 [INFO] [stdout] | [INFO] [stdout] 82 | / if adjacency_map.contains_key(&node) { [INFO] [stdout] 83 | | adjacency_map.get(&node).unwrap().union(&neighbors); [INFO] [stdout] 84 | | } else { [INFO] [stdout] 85 | | adjacency_map.insert(node, neighbors); [INFO] [stdout] 86 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_entry [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 82 ~ if let std::collections::hash_map::Entry::Vacant(e) = adjacency_map.entry(node) { [INFO] [stdout] 83 + e.insert(neighbors); [INFO] [stdout] 84 + } else { [INFO] [stdout] 85 + adjacency_map.get(&node).unwrap().union(&neighbors); [INFO] [stdout] 86 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/dueling_generators_15.rs:43:5 [INFO] [stdout] | [INFO] [stdout] 43 | return prev; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 43 - return prev; [INFO] [stdout] 43 + prev [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/duet_18.rs:70:5 [INFO] [stdout] | [INFO] [stdout] 70 | return last_played; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 70 - return last_played; [INFO] [stdout] 70 + last_played [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: usage of `contains_key` followed by `insert` on a `HashMap` [INFO] [stdout] --> src/duet_18.rs:20:9 [INFO] [stdout] | [INFO] [stdout] 20 | / if !register_map.contains_key(&target_register) { [INFO] [stdout] 21 | | register_map.insert(target_register, 0); [INFO] [stdout] 22 | | } [INFO] [stdout] | |_________^ help: try: `register_map.entry(target_register).or_insert(0);` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_entry [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: equality checks against true are unnecessary [INFO] [stdout] --> src/halting_problem_25.rs:50:28 [INFO] [stdout] | [INFO] [stdout] 50 | tape.iter().filter(|x| **x == true).count() [INFO] [stdout] | ^^^^^^^^^^^ help: try: `**x` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_comparison [INFO] [stdout] = note: `#[warn(clippy::bool_comparison)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: equality checks against true are unnecessary [INFO] [stdout] --> src/halting_problem_25.rs:175:28 [INFO] [stdout] | [INFO] [stdout] 175 | tape.iter().filter(|x| **x == true).count() [INFO] [stdout] | ^^^^^^^^^^^ help: try: `**x` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_comparison [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/packet_scanners_13.rs:50:5 [INFO] [stdout] | [INFO] [stdout] 50 | return severity; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 50 - return severity; [INFO] [stdout] 50 + severity [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/packet_scanners_13.rs:8:28 [INFO] [stdout] | [INFO] [stdout] 8 | scanner_pos.insert(depth.clone(), 0); [INFO] [stdout] | ^^^^^^^^^^^^^ help: try dereferencing it: `*depth` [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: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/packet_scanners_13.rs:12:29 [INFO] [stdout] | [INFO] [stdout] 12 | scanner_flag.insert(depth.clone(), false); [INFO] [stdout] | ^^^^^^^^^^^^^ help: try dereferencing it: `*depth` [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: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/packet_scanners_13.rs:16:20 [INFO] [stdout] | [INFO] [stdout] 16 | scn.insert(k.clone(), v.clone()); [INFO] [stdout] | ^^^^^^^^^ help: try dereferencing it: `*k` [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: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/packet_scanners_13.rs:16:31 [INFO] [stdout] | [INFO] [stdout] 16 | scn.insert(k.clone(), v.clone()); [INFO] [stdout] | ^^^^^^^^^ help: try dereferencing it: `*v` [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 `if` statement can be collapsed [INFO] [stdout] --> src/packet_scanners_13.rs:25:9 [INFO] [stdout] | [INFO] [stdout] 25 | / if scanner_pos.contains_key(¤t_depth) { [INFO] [stdout] 26 | | if *scanner_pos.get(¤t_depth).unwrap() == 0 { [INFO] [stdout] 27 | | severity += current_depth * scn.get(¤t_depth).unwrap() [INFO] [stdout] 28 | | } [INFO] [stdout] 29 | | } [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] 25 ~ if scanner_pos.contains_key(¤t_depth) [INFO] [stdout] 26 ~ && *scanner_pos.get(¤t_depth).unwrap() == 0 { [INFO] [stdout] 27 | severity += current_depth * scn.get(¤t_depth).unwrap() [INFO] [stdout] 28 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u16` which implements the `Copy` trait [INFO] [stdout] --> src/packet_scanners_13.rs:31:48 [INFO] [stdout] | [INFO] [stdout] 31 | if *scanner_pos.get(k).unwrap() == scn.get(k).unwrap().clone() - 1 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try dereferencing it: `*scn.get(k).unwrap()` [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 `if` statement can be collapsed [INFO] [stdout] --> src/packet_scanners_13.rs:35:20 [INFO] [stdout] | [INFO] [stdout] 35 | } else if *scanner_pos.get(k).unwrap() == 0 { [INFO] [stdout] | ____________________^ [INFO] [stdout] 36 | | if scanner_flag.get(k).unwrap() == &true { [INFO] [stdout] 37 | | *scanner_flag.get_mut(k).unwrap() = false; [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 ~ } else if *scanner_pos.get(k).unwrap() == 0 [INFO] [stdout] 36 ~ && scanner_flag.get(k).unwrap() == &true { [INFO] [stdout] 37 | *scanner_flag.get_mut(k).unwrap() = false; [INFO] [stdout] 38 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/packet_scanners_13.rs:64:5 [INFO] [stdout] | [INFO] [stdout] 64 | return scanners; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 64 - return scanners; [INFO] [stdout] 64 + scanners [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/particle_swarm_20.rs:27:34 [INFO] [stdout] | [INFO] [stdout] 27 | fn find_closest_index(particles: &Vec) -> 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] = note: `#[warn(clippy::ptr_arg)]` on by default [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 27 - fn find_closest_index(particles: &Vec) -> usize { [INFO] [stdout] 27 + fn find_closest_index(particles: &[Particle]) -> usize { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `filter(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find(..)` instead [INFO] [stdout] --> src/recursive_circus_7.rs:18:5 [INFO] [stdout] | [INFO] [stdout] 18 | / program_map.keys() [INFO] [stdout] 19 | | .filter(|x| !parent_map.contains_key(x.as_str())) [INFO] [stdout] 20 | | .next() [INFO] [stdout] | |_______________^ help: try: `program_map.keys().find(|x| !parent_map.contains_key(x.as_str()))` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#filter_next [INFO] [stdout] = note: `#[warn(clippy::filter_next)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/registers_8.rs:23:20 [INFO] [stdout] | [INFO] [stdout] 23 | if !(registers[&condition_register] > condition_val) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(registers[&condition_register] <= condition_val)` [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] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/registers_8.rs:28:20 [INFO] [stdout] | [INFO] [stdout] 28 | if !(registers[&condition_register] < condition_val) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(registers[&condition_register] >= condition_val)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/registers_8.rs:33:20 [INFO] [stdout] | [INFO] [stdout] 33 | if !(registers[&condition_register] == condition_val) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(registers[&condition_register] != condition_val)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/registers_8.rs:38:20 [INFO] [stdout] | [INFO] [stdout] 38 | if !(registers[&condition_register] >= condition_val) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(registers[&condition_register] < condition_val)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/registers_8.rs:43:20 [INFO] [stdout] | [INFO] [stdout] 43 | if !(registers[&condition_register] <= condition_val) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(registers[&condition_register] > condition_val)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/registers_8.rs:48:20 [INFO] [stdout] | [INFO] [stdout] 48 | if !(registers[&condition_register] != condition_val) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(registers[&condition_register] == condition_val)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/spinlock_17.rs:5:5 [INFO] [stdout] | [INFO] [stdout] 5 | return next_pos; [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] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 5 - return next_pos; [INFO] [stdout] 5 + next_pos [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: usage of `contains_key` followed by `insert` on a `HashMap` [INFO] [stdout] --> src/spinlock_17.rs:80:13 [INFO] [stdout] | [INFO] [stdout] 80 | / if !index_map.contains_key(&b[1]) { [INFO] [stdout] 81 | | index_map.insert(b[1], i); [INFO] [stdout] 82 | | } [INFO] [stdout] | |_____________^ help: try: `index_map.entry(b[1]).or_insert(i);` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_entry [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting to the same type is unnecessary (`usize` -> `usize`) [INFO] [stdout] --> src/spiral_memory_3.rs:59:5 [INFO] [stdout] | [INFO] [stdout] 59 | (layer + dist2 as usize) as usize [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(layer + dist2 as usize)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this multiplication by -1 can be written more succinctly [INFO] [stdout] --> src/sporifica_virus_22.rs:101:19 [INFO] [stdout] | [INFO] [stdout] 101 | let mut yid = -1 * dim / 2; [INFO] [stdout] | ^^^^^^^^ help: consider using: `-dim` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#neg_multiply [INFO] [stdout] = note: `#[warn(clippy::neg_multiply)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `i` is used to index `route_map` [INFO] [stdout] --> src/tubes_19.rs:35:14 [INFO] [stdout] | [INFO] [stdout] 35 | for i in 0..route_map[0].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 and enumerate() [INFO] [stdout] | [INFO] [stdout] 35 - for i in 0..route_map[0].len() { [INFO] [stdout] 35 + for (i, ) in route_map.iter().enumerate().take(route_map[0].len()) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/tubes_19.rs:61:13 [INFO] [stdout] | [INFO] [stdout] 61 | / if (packet.loc.x as usize + 1) < route_map.len() [INFO] [stdout] 62 | | && route_map[packet.loc.x as usize + 1][packet.loc.y as usize] != ' ' [INFO] [stdout] 63 | | { [INFO] [stdout] 64 | | if packet.direction != Direction::Up { [INFO] [stdout] ... | [INFO] [stdout] 67 | | } [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] 62 ~ && route_map[packet.loc.x as usize + 1][packet.loc.y as usize] != ' ' [INFO] [stdout] 63 ~ && packet.direction != Direction::Up { [INFO] [stdout] 64 | new_dir = Direction::Down; [INFO] [stdout] 65 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/tubes_19.rs:68:13 [INFO] [stdout] | [INFO] [stdout] 68 | / if (packet.loc.x - 1) >= 0 [INFO] [stdout] 69 | | && route_map[packet.loc.x as usize - 1][packet.loc.y as usize] != ' ' [INFO] [stdout] 70 | | { [INFO] [stdout] 71 | | if packet.direction != Direction::Down { [INFO] [stdout] ... | [INFO] [stdout] 74 | | } [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] 69 ~ && route_map[packet.loc.x as usize - 1][packet.loc.y as usize] != ' ' [INFO] [stdout] 70 ~ && packet.direction != Direction::Down { [INFO] [stdout] 71 | new_dir = Direction::Up; [INFO] [stdout] 72 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/tubes_19.rs:75:13 [INFO] [stdout] | [INFO] [stdout] 75 | / if (packet.loc.y as usize + 1) < route_map[packet.loc.x as usize].len() [INFO] [stdout] 76 | | && route_map[packet.loc.x as usize][packet.loc.y as usize + 1] != ' ' [INFO] [stdout] 77 | | { [INFO] [stdout] 78 | | if packet.direction != Direction::Left { [INFO] [stdout] ... | [INFO] [stdout] 81 | | } [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] 76 ~ && route_map[packet.loc.x as usize][packet.loc.y as usize + 1] != ' ' [INFO] [stdout] 77 ~ && packet.direction != Direction::Left { [INFO] [stdout] 78 | new_dir = Direction::Right; [INFO] [stdout] 79 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/tubes_19.rs:82:13 [INFO] [stdout] | [INFO] [stdout] 82 | / if (packet.loc.y - 1) >= 0 [INFO] [stdout] 83 | | && route_map[packet.loc.x as usize][packet.loc.y as usize - 1] != ' ' [INFO] [stdout] 84 | | { [INFO] [stdout] 85 | | if packet.direction != Direction::Right { [INFO] [stdout] ... | [INFO] [stdout] 88 | | } [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] 83 ~ && route_map[packet.loc.x as usize][packet.loc.y as usize - 1] != ' ' [INFO] [stdout] 84 ~ && packet.direction != Direction::Right { [INFO] [stdout] 85 | new_dir = Direction::Left; [INFO] [stdout] 86 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `i` is only used to index `lines` [INFO] [stdout] --> src/tubes_19.rs:120:18 [INFO] [stdout] | [INFO] [stdout] 120 | for i in 0..6 { [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] 120 - for i in 0..6 { [INFO] [stdout] 120 + for in lines.iter_mut().take(6) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `i` is only used to index `lines` [INFO] [stdout] --> src/tubes_19.rs:142:18 [INFO] [stdout] | [INFO] [stdout] 142 | for i in 0..lines.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] 142 - for i in 0..lines.len() { [INFO] [stdout] 142 + for in &mut lines { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/memory_realloc_6.rs:39:21 [INFO] [stdout] | [INFO] [stdout] 39 | let banks = vec![0, 2, 7, 0]; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: you can use an array directly: `[0, 2, 7, 0]` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] = note: `#[warn(clippy::useless_vec)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 3.85s [INFO] [stdout] warning: unused `std::collections::hash_set::Union` that must be used [INFO] [stdout] --> src/digital_plumber_12.rs:83:13 [INFO] [stdout] | [INFO] [stdout] 83 | adjacency_map.get(&node).unwrap().union(&neighbors); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: this returns the union as an iterator, without modifying either input set [INFO] [stdout] = note: `#[warn(unused_must_use)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: use `let _ = ...` to ignore the resulting value [INFO] [stdout] | [INFO] [stdout] 83 | let _ = adjacency_map.get(&node).unwrap().union(&neighbors); [INFO] [stdout] | +++++++ [INFO] [stdout] [INFO] [stdout] [INFO] running `Command { std: "docker" "inspect" "97ad1faab45c18619239ae74887381a58704ec032022d0eead13832a29fae870", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "97ad1faab45c18619239ae74887381a58704ec032022d0eead13832a29fae870", kill_on_drop: false }` [INFO] [stdout] 97ad1faab45c18619239ae74887381a58704ec032022d0eead13832a29fae870