[INFO] cloning repository https://github.com/TheQuantumGhost/advent2020-public [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/TheQuantumGhost/advent2020-public" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FTheQuantumGhost%2Fadvent2020-public", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FTheQuantumGhost%2Fadvent2020-public'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 7d87a9e5dc266aa30b53332af9aa2f23293e199f [INFO] linting TheQuantumGhost/advent2020-public against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FTheQuantumGhost%2Fadvent2020-public" "/workspace/builds/worker-5-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-5-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/TheQuantumGhost/advent2020-public [INFO] finished tweaking git repo https://github.com/TheQuantumGhost/advent2020-public [INFO] tweaked toml for git repo https://github.com/TheQuantumGhost/advent2020-public written to /workspace/builds/worker-5-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/TheQuantumGhost/advent2020-public 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/TheQuantumGhost/advent2020-public 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-5-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-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] 0ea77eb2e820f99c98015d2dd9ec2bd03cc1169729c982af079d10cf2ba7cbdc [INFO] running `Command { std: "docker" "start" "-a" "0ea77eb2e820f99c98015d2dd9ec2bd03cc1169729c982af079d10cf2ba7cbdc", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "0ea77eb2e820f99c98015d2dd9ec2bd03cc1169729c982af079d10cf2ba7cbdc", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "0ea77eb2e820f99c98015d2dd9ec2bd03cc1169729c982af079d10cf2ba7cbdc", kill_on_drop: false }` [INFO] [stdout] 0ea77eb2e820f99c98015d2dd9ec2bd03cc1169729c982af079d10cf2ba7cbdc [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-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] 1809ffecab17963f5157c9592bd1a57cb1adcc42ccdbe0df474be885f920a424 [INFO] running `Command { std: "docker" "start" "-a" "1809ffecab17963f5157c9592bd1a57cb1adcc42ccdbe0df474be885f920a424", kill_on_drop: false }` [INFO] [stderr] Compiling unicode-ident v1.0.20 [INFO] [stderr] Checking grid v1.0.0 [INFO] [stderr] Checking num-integer v0.1.46 [INFO] [stderr] Checking num-complex v0.4.6 [INFO] [stderr] Checking proc-macro2 v1.0.103 [INFO] [stderr] Checking num-bigint v0.4.6 [INFO] [stderr] Checking num-iter v0.1.45 [INFO] [stderr] Checking quote v1.0.41 [INFO] [stderr] Checking syn v2.0.108 [INFO] [stderr] Checking num-rational v0.4.2 [INFO] [stderr] Checking num v0.4.3 [INFO] [stderr] Compiling thiserror-impl v2.0.17 [INFO] [stderr] Checking thiserror v2.0.17 [INFO] [stderr] Compiling utilities v0.1.0 (/opt/rustwide/workdir/utilities) [INFO] [stdout] warning: accessing first element with `input.get(0)` [INFO] [stdout] --> utilities/src/parsers/simple_parser/parser_peek.rs:11:26 [INFO] [stdout] | [INFO] [stdout] 11 | if let Some(t) = input.get(0) { [INFO] [stdout] | ^^^^^^^^^^^^ help: try: `input.first()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first [INFO] [stdout] = note: `#[warn(clippy::get_first)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: accessing first element with `input.get(0)` [INFO] [stdout] --> utilities/src/parsers/simple_parser/parser_satisfy.rs:14:26 [INFO] [stdout] | [INFO] [stdout] 14 | if let Some(t) = input.get(0) [INFO] [stdout] | ^^^^^^^^^^^^ help: try: `input.first()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: accessing first element with `input.get(0)` [INFO] [stdout] --> utilities/src/parsers/simple_parser/parser_peek.rs:11:26 [INFO] [stdout] | [INFO] [stdout] 11 | if let Some(t) = input.get(0) { [INFO] [stdout] | ^^^^^^^^^^^^ help: try: `input.first()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first [INFO] [stdout] = note: `#[warn(clippy::get_first)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: accessing first element with `input.get(0)` [INFO] [stdout] --> utilities/src/parsers/simple_parser/parser_satisfy.rs:14:26 [INFO] [stdout] | [INFO] [stdout] 14 | if let Some(t) = input.get(0) [INFO] [stdout] | ^^^^^^^^^^^^ help: try: `input.first()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: accessing first element with `input.get(0)` [INFO] [stdout] --> utilities/src/parsers/simple_parser/parser_tag.rs:13:26 [INFO] [stdout] | [INFO] [stdout] 13 | if let Some(c) = input.get(0) [INFO] [stdout] | ^^^^^^^^^^^^ help: try: `input.first()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: accessing first element with `input.get(0)` [INFO] [stdout] --> utilities/src/parsers/simple_parser/parser_tag.rs:13:26 [INFO] [stdout] | [INFO] [stdout] 13 | if let Some(c) = input.get(0) [INFO] [stdout] | ^^^^^^^^^^^^ help: try: `input.first()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: accessing first element with `input.get(0)` [INFO] [stdout] --> utilities/src/parsers/simple_parser/parser_peek.rs:11:26 [INFO] [stdout] | [INFO] [stdout] 11 | if let Some(t) = input.get(0) { [INFO] [stdout] | ^^^^^^^^^^^^ help: try: `input.first()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first [INFO] [stdout] = note: `#[warn(clippy::get_first)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: accessing first element with `input.get(0)` [INFO] [stdout] --> utilities/src/parsers/simple_parser/parser_satisfy.rs:14:26 [INFO] [stdout] | [INFO] [stdout] 14 | if let Some(t) = input.get(0) [INFO] [stdout] | ^^^^^^^^^^^^ help: try: `input.first()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: accessing first element with `input.get(0)` [INFO] [stdout] --> utilities/src/parsers/simple_parser/parser_tag.rs:13:26 [INFO] [stdout] | [INFO] [stdout] 13 | if let Some(c) = input.get(0) [INFO] [stdout] | ^^^^^^^^^^^^ help: try: `input.first()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Checking day03 v0.1.0 (/opt/rustwide/workdir/day03) [INFO] [stderr] Checking day05 v0.1.0 (/opt/rustwide/workdir/day05) [INFO] [stderr] Checking day09 v0.1.0 (/opt/rustwide/workdir/day09) [INFO] [stderr] Checking day01 v0.1.0 (/opt/rustwide/workdir/day01) [INFO] [stderr] Checking day06 v0.1.0 (/opt/rustwide/workdir/day06) [INFO] [stderr] Checking day10 v0.1.0 (/opt/rustwide/workdir/day10) [INFO] [stderr] Checking day15 v0.1.0 (/opt/rustwide/workdir/day15) [INFO] [stderr] Checking day07 v0.1.0 (/opt/rustwide/workdir/day07) [INFO] [stderr] Checking day11 v0.1.0 (/opt/rustwide/workdir/day11) [INFO] [stderr] Checking day14 v0.1.0 (/opt/rustwide/workdir/day14) [INFO] [stderr] Checking day13 v0.1.0 (/opt/rustwide/workdir/day13) [INFO] [stderr] Checking day20 v0.1.0 (/opt/rustwide/workdir/day20) [INFO] [stderr] Compiling derive_from_char v0.1.0 (/opt/rustwide/workdir/derive_from_char) [INFO] [stdout] warning: this `.fold` can be written more succinctly using another method [INFO] [stdout] --> day03/src/main.rs:43:10 [INFO] [stdout] | [INFO] [stdout] 43 | .fold(1, |acc, v| acc * v) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `product()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_fold [INFO] [stdout] = note: `#[warn(clippy::unnecessary_fold)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> day10/src/main.rs:52:5 [INFO] [stdout] | [INFO] [stdout] 52 | return count_possibilities(&ways, 0); [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] 52 - return count_possibilities(&ways, 0); [INFO] [stdout] 52 + count_possibilities(&ways, 0) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `.fold` can be written more succinctly using another method [INFO] [stdout] --> day03/src/main.rs:43:10 [INFO] [stdout] | [INFO] [stdout] 43 | .fold(1, |acc, v| acc * v) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `product()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_fold [INFO] [stdout] = note: `#[warn(clippy::unnecessary_fold)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Checking day12 v0.1.0 (/opt/rustwide/workdir/day12) [INFO] [stderr] Checking day16 v0.1.0 (/opt/rustwide/workdir/day16) [INFO] [stderr] Checking day08 v0.1.0 (/opt/rustwide/workdir/day08) [INFO] [stderr] Checking day18 v0.1.0 (/opt/rustwide/workdir/day18) [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> day06/src/main.rs:21:12 [INFO] [stdout] | [INFO] [stdout] 21 | if self.answers.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.answers.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] = note: `#[warn(clippy::len_zero)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you are using an explicit closure for copying elements [INFO] [stdout] --> day06/src/main.rs:28:23 [INFO] [stdout] | [INFO] [stdout] 28 | acc = acc.union(answer).map(|c| *c).collect::>(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider calling the dedicated `copied` method: `acc.union(answer).copied()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stdout] = note: `#[warn(clippy::map_clone)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> day06/src/main.rs:34:12 [INFO] [stdout] | [INFO] [stdout] 34 | if self.answers.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.answers.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `k` is only used to index `input` [INFO] [stdout] --> day01/src/main.rs:35:22 [INFO] [stdout] | [INFO] [stdout] 35 | for k in (j + 1)..l { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] = note: `#[warn(clippy::needless_range_loop)]` on by default [INFO] [stdout] help: consider using an iterator [INFO] [stdout] | [INFO] [stdout] 35 - for k in (j + 1)..l { [INFO] [stdout] 35 + for in input.iter().take(l).skip((j + 1)) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `input` [INFO] [stdout] --> day20/src/main.rs:11:19 [INFO] [stdout] | [INFO] [stdout] 11 | fn resolve_simple(input: &()) -> usize { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_input` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `input` [INFO] [stdout] --> day20/src/main.rs:15:20 [INFO] [stdout] | [INFO] [stdout] 15 | fn resolve_complex(input: &()) -> usize { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_input` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you are using an explicit closure for copying elements [INFO] [stdout] --> day06/src/main.rs:41:23 [INFO] [stdout] | [INFO] [stdout] 41 | acc = acc [INFO] [stdout] | _______________________^ [INFO] [stdout] 42 | | .intersection(answer) [INFO] [stdout] 43 | | .map(|c| *c) [INFO] [stdout] | |________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stdout] help: consider calling the dedicated `copied` method [INFO] [stdout] | [INFO] [stdout] 41 ~ acc = acc [INFO] [stdout] 42 + .intersection(answer).copied() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: importing legacy numeric constants [INFO] [stdout] --> day14/src/main.rs:1:47 [INFO] [stdout] | [INFO] [stdout] 1 | use std::{collections::HashMap, str::FromStr, usize}; [INFO] [stdout] | ^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: remove this import [INFO] [stdout] = note: then `usize::` will resolve to the respective associated constant [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants [INFO] [stdout] = note: `#[warn(clippy::legacy_numeric_constants)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the loop variable `k` is only used to index `input` [INFO] [stdout] --> day01/src/main.rs:35:22 [INFO] [stdout] | [INFO] [stdout] 35 | for k in (j + 1)..l { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop [INFO] [stdout] = note: `#[warn(clippy::needless_range_loop)]` on by default [INFO] [stdout] help: consider using an iterator [INFO] [stdout] | [INFO] [stdout] 35 - for k in (j + 1)..l { [INFO] [stdout] 35 + for in input.iter().take(l).skip((j + 1)) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> derive_from_char/src/fromchar.rs:15:22 [INFO] [stdout] | [INFO] [stdout] 15 | .map(|variant| parse_variant(variant)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `parse_variant` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] = note: `#[warn(clippy::redundant_closure)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: importing legacy numeric constants [INFO] [stdout] --> day14/src/main.rs:1:47 [INFO] [stdout] | [INFO] [stdout] 1 | use std::{collections::HashMap, str::FromStr, usize}; [INFO] [stdout] | ^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: remove this import [INFO] [stdout] = note: then `usize::` will resolve to the respective associated constant [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants [INFO] [stdout] = note: `#[warn(clippy::legacy_numeric_constants)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> day13/src/main.rs:40:9 [INFO] [stdout] | [INFO] [stdout] 40 | / if let Some(y) = maybe_id { [INFO] [stdout] 41 | | if ids [INFO] [stdout] 42 | | .iter() [INFO] [stdout] 43 | | .filter_map(|id| *id) [INFO] [stdout] ... | [INFO] [stdout] 49 | | } [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] 40 ~ if let Some(y) = maybe_id [INFO] [stdout] 41 ~ && ids [INFO] [stdout] 42 | .iter() [INFO] [stdout] ... [INFO] [stdout] 47 | return false; [INFO] [stdout] 48 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> derive_from_char/src/fromchar.rs:15:22 [INFO] [stdout] | [INFO] [stdout] 15 | .map(|variant| parse_variant(variant)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `parse_variant` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] = note: `#[warn(clippy::redundant_closure)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `Iterator::find` [INFO] [stdout] --> day13/src/main.rs:86:5 [INFO] [stdout] | [INFO] [stdout] 86 | / for i in 1..m { [INFO] [stdout] 87 | | //eprintln!("{x} * {i} = {}", (x * i).rem_euclid(m)); [INFO] [stdout] 88 | | if (x * i).rem_euclid(m) == 1 { [INFO] [stdout] 89 | | return Some(i); [INFO] [stdout] ... | [INFO] [stdout] 92 | | None [INFO] [stdout] | |________^ help: replace with an iterator: `(1..m).find(|&i| (x * i).rem_euclid(m) == 1)` [INFO] [stdout] | [INFO] [stdout] = note: you may need to dereference some variables [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_find [INFO] [stdout] = note: `#[warn(clippy::manual_find)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `proc_macro2::TokenStream` [INFO] [stdout] --> derive_from_char/src/lib.rs:19:31 [INFO] [stdout] | [INFO] [stdout] 19 | to_compile_error(err, dummy.into()).into() [INFO] [stdout] | ^^^^^^^^^^^^ help: consider removing `.into()`: `dummy` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] = note: `#[warn(clippy::useless_conversion)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> day06/src/main.rs:21:12 [INFO] [stdout] | [INFO] [stdout] 21 | if self.answers.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.answers.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] = note: `#[warn(clippy::len_zero)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you are using an explicit closure for copying elements [INFO] [stdout] --> day06/src/main.rs:28:23 [INFO] [stdout] | [INFO] [stdout] 28 | acc = acc.union(answer).map(|c| *c).collect::>(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider calling the dedicated `copied` method: `acc.union(answer).copied()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stdout] = note: `#[warn(clippy::map_clone)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> day06/src/main.rs:34:12 [INFO] [stdout] | [INFO] [stdout] 34 | if self.answers.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.answers.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you are using an explicit closure for copying elements [INFO] [stdout] --> day06/src/main.rs:41:23 [INFO] [stdout] | [INFO] [stdout] 41 | acc = acc [INFO] [stdout] | _______________________^ [INFO] [stdout] 42 | | .intersection(answer) [INFO] [stdout] 43 | | .map(|c| *c) [INFO] [stdout] | |________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stdout] help: consider calling the dedicated `copied` method [INFO] [stdout] | [INFO] [stdout] 41 ~ acc = acc [INFO] [stdout] 42 + .intersection(answer).copied() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you are using an explicit closure for copying elements [INFO] [stdout] --> day11/src/main.rs:92:30 [INFO] [stdout] | [INFO] [stdout] 92 | .filter_map(|(x, y)| current.get(x as usize, y as usize).map(|c| *c)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider calling the dedicated `copied` method: `current.get(x as usize, y as usize).copied()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stdout] = note: `#[warn(clippy::map_clone)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> day08/src/main.rs:16:13 [INFO] [stdout] | [INFO] [stdout] 16 | / return Err(Self::Err::MismatchedLength { [INFO] [stdout] 17 | | expect: 2, [INFO] [stdout] 18 | | got: splits.len(), [INFO] [stdout] 19 | | }); [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] 16 ~ Err(Self::Err::MismatchedLength { [INFO] [stdout] 17 + expect: 2, [INFO] [stdout] 18 + got: splits.len(), [INFO] [stdout] 19 ~ }) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `proc_macro2::TokenStream` [INFO] [stdout] --> derive_from_char/src/lib.rs:19:31 [INFO] [stdout] | [INFO] [stdout] 19 | to_compile_error(err, dummy.into()).into() [INFO] [stdout] | ^^^^^^^^^^^^ help: consider removing `.into()`: `dummy` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] = note: `#[warn(clippy::useless_conversion)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> day08/src/main.rs:107:27 [INFO] [stdout] | [INFO] [stdout] 107 | fn resolve_complex(input: &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] 107 ~ fn resolve_complex(input: &[Operation]) -> usize { [INFO] [stdout] 108 | for (i, op) in input.iter().enumerate() { [INFO] [stdout] 109 | let program = if let Operation::Jmp(val) = *op { [INFO] [stdout] 110 ~ let mut program = input.to_owned(); [INFO] [stdout] 111 | program[i] = Operation::Nop(val); [INFO] [stdout] 112 | program [INFO] [stdout] 113 | } else if let Operation::Nop(val) = *op { [INFO] [stdout] 114 ~ let mut program = input.to_owned(); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> day16/src/types.rs:116:13 [INFO] [stdout] | [INFO] [stdout] 116 | ticket: ticket, [INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace it with: `ticket` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stdout] = note: `#[warn(clippy::redundant_field_names)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Checking day02 v0.1.0 (/opt/rustwide/workdir/day02) [INFO] [stderr] Checking day04 v0.1.0 (/opt/rustwide/workdir/day04) [INFO] [stdout] warning: this expression borrows a value the compiler would automatically borrow [INFO] [stdout] --> day07/src/main.rs:18:22 [INFO] [stdout] | [INFO] [stdout] 18 | let splits = (&s.trim()[..s.len() - 1]) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: change this to: `s.trim()[..s.len() - 1]` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> day10/src/main.rs:52:5 [INFO] [stdout] | [INFO] [stdout] 52 | return count_possibilities(&ways, 0); [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] 52 - return count_possibilities(&ways, 0); [INFO] [stdout] 52 + count_possibilities(&ways, 0) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you are using an explicit closure for copying elements [INFO] [stdout] --> day07/src/main.rs:100:19 [INFO] [stdout] | [INFO] [stdout] 100 | let tmp = tmp.union(&set).map(|bag| *bag).collect::>(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider calling the dedicated `copied` method: `tmp.union(&set).copied()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stdout] = note: `#[warn(clippy::map_clone)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `input` [INFO] [stdout] --> day20/src/main.rs:11:19 [INFO] [stdout] | [INFO] [stdout] 11 | fn resolve_simple(input: &()) -> usize { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_input` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you are using an explicit closure for copying elements [INFO] [stdout] --> day11/src/main.rs:92:30 [INFO] [stdout] | [INFO] [stdout] 92 | .filter_map(|(x, y)| current.get(x as usize, y as usize).map(|c| *c)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider calling the dedicated `copied` method: `current.get(x as usize, y as usize).copied()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stdout] = note: `#[warn(clippy::map_clone)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `input` [INFO] [stdout] --> day20/src/main.rs:15:20 [INFO] [stdout] | [INFO] [stdout] 15 | fn resolve_complex(input: &()) -> usize { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_input` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this let-binding has unit value [INFO] [stdout] --> day20/src/main.rs:29:9 [INFO] [stdout] | [INFO] [stdout] 29 | let input = read_input(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_unit_value [INFO] [stdout] = note: `#[warn(clippy::let_unit_value)]` on by default [INFO] [stdout] help: omit the `let` binding and replace variable usages with `()` [INFO] [stdout] | [INFO] [stdout] 29 ~ read_input(); [INFO] [stdout] 30 ~ assert_eq!(0, resolve_simple(&())); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this let-binding has unit value [INFO] [stdout] --> day20/src/main.rs:34:9 [INFO] [stdout] | [INFO] [stdout] 34 | let input = read_input(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_unit_value [INFO] [stdout] help: omit the `let` binding and replace variable usages with `()` [INFO] [stdout] | [INFO] [stdout] 34 ~ read_input(); [INFO] [stdout] 35 ~ assert_eq!(0, resolve_complex(&())); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> day16/src/types.rs:116:13 [INFO] [stdout] | [INFO] [stdout] 116 | ticket: ticket, [INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace it with: `ticket` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stdout] = note: `#[warn(clippy::redundant_field_names)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression borrows a value the compiler would automatically borrow [INFO] [stdout] --> day07/src/main.rs:18:22 [INFO] [stdout] | [INFO] [stdout] 18 | let splits = (&s.trim()[..s.len() - 1]) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: change this to: `s.trim()[..s.len() - 1]` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you are using an explicit closure for copying elements [INFO] [stdout] --> day07/src/main.rs:100:19 [INFO] [stdout] | [INFO] [stdout] 100 | let tmp = tmp.union(&set).map(|bag| *bag).collect::>(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider calling the dedicated `copied` method: `tmp.union(&set).copied()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stdout] = note: `#[warn(clippy::map_clone)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Checking day17 v0.1.0 (/opt/rustwide/workdir/day17) [INFO] [stdout] warning: manual `RangeInclusive::contains` implementation [INFO] [stdout] --> day04/src/main.rs:39:17 [INFO] [stdout] | [INFO] [stdout] 39 | 1920 <= year && year <= 2002 [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use: `(1920..=2002).contains(&year)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_range_contains [INFO] [stdout] = note: `#[warn(clippy::manual_range_contains)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual `RangeInclusive::contains` implementation [INFO] [stdout] --> day04/src/main.rs:52:17 [INFO] [stdout] | [INFO] [stdout] 52 | 2010 <= year && year <= 2020 [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use: `(2010..=2020).contains(&year)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_range_contains [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual `RangeInclusive::contains` implementation [INFO] [stdout] --> day04/src/main.rs:65:17 [INFO] [stdout] | [INFO] [stdout] 65 | 2020 <= year && year <= 2030 [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use: `(2020..=2030).contains(&year)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_range_contains [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual `RangeInclusive::contains` implementation [INFO] [stdout] --> day04/src/main.rs:39:17 [INFO] [stdout] | [INFO] [stdout] 39 | 1920 <= year && year <= 2002 [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use: `(1920..=2002).contains(&year)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_range_contains [INFO] [stdout] = note: `#[warn(clippy::manual_range_contains)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual `RangeInclusive::contains` implementation [INFO] [stdout] --> day04/src/main.rs:52:17 [INFO] [stdout] | [INFO] [stdout] 52 | 2010 <= year && year <= 2020 [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use: `(2010..=2020).contains(&year)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_range_contains [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual `RangeInclusive::contains` implementation [INFO] [stdout] --> day04/src/main.rs:65:17 [INFO] [stdout] | [INFO] [stdout] 65 | 2020 <= year && year <= 2030 [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use: `(2020..=2030).contains(&year)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_range_contains [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> day08/src/main.rs:16:13 [INFO] [stdout] | [INFO] [stdout] 16 | / return Err(Self::Err::MismatchedLength { [INFO] [stdout] 17 | | expect: 2, [INFO] [stdout] 18 | | got: splits.len(), [INFO] [stdout] 19 | | }); [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] 16 ~ Err(Self::Err::MismatchedLength { [INFO] [stdout] 17 + expect: 2, [INFO] [stdout] 18 + got: splits.len(), [INFO] [stdout] 19 ~ }) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> day04/src/main.rs:112:9 [INFO] [stdout] | [INFO] [stdout] 112 | / self.check_byr() [INFO] [stdout] 113 | | && self.check_iyr() [INFO] [stdout] 114 | | && self.check_eyr() [INFO] [stdout] 115 | | && check_hgt [INFO] [stdout] ... | [INFO] [stdout] 118 | | && check_ecl [INFO] [stdout] 119 | | && check_pid [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 117 - && check_hcl [INFO] [stdout] 118 - && check_ecl [INFO] [stdout] 119 - && check_pid [INFO] [stdout] 112 + !(!self.check_byr() || !self.check_iyr() || !self.check_eyr() || !check_hgt || !check_hcl || !check_ecl || !check_pid) [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 117 - && check_hcl [INFO] [stdout] 118 - && check_ecl [INFO] [stdout] 119 - && check_pid [INFO] [stdout] 112 + self.check_byr() && self.check_iyr() && self.check_eyr() && check_hgt && check_hcl && check_ecl && check_pid [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> day04/src/main.rs:112:9 [INFO] [stdout] | [INFO] [stdout] 112 | / self.check_byr() [INFO] [stdout] 113 | | && self.check_iyr() [INFO] [stdout] 114 | | && self.check_eyr() [INFO] [stdout] 115 | | && check_hgt [INFO] [stdout] 116 | | && check_hgt [INFO] [stdout] 117 | | && check_hcl [INFO] [stdout] 118 | | && check_ecl [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 117 - && check_hcl [INFO] [stdout] 118 - && check_ecl [INFO] [stdout] 112 + !(!self.check_byr() || !self.check_iyr() || !self.check_eyr() || !check_hgt || !check_hcl || !check_ecl) [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 117 - && check_hcl [INFO] [stdout] 118 - && check_ecl [INFO] [stdout] 112 + self.check_byr() && self.check_iyr() && self.check_eyr() && check_hgt && check_hcl && check_ecl [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> day04/src/main.rs:112:9 [INFO] [stdout] | [INFO] [stdout] 112 | / self.check_byr() [INFO] [stdout] 113 | | && self.check_iyr() [INFO] [stdout] 114 | | && self.check_eyr() [INFO] [stdout] 115 | | && check_hgt [INFO] [stdout] 116 | | && check_hgt [INFO] [stdout] 117 | | && check_hcl [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 117 - && check_hcl [INFO] [stdout] 112 + !(!self.check_byr() || !self.check_iyr() || !self.check_eyr() || !check_hgt || !check_hcl) [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 117 - && check_hcl [INFO] [stdout] 112 + self.check_byr() && self.check_iyr() && self.check_eyr() && check_hgt && check_hcl [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> day04/src/main.rs:112:9 [INFO] [stdout] | [INFO] [stdout] 112 | / self.check_byr() [INFO] [stdout] 113 | | && self.check_iyr() [INFO] [stdout] 114 | | && self.check_eyr() [INFO] [stdout] 115 | | && check_hgt [INFO] [stdout] 116 | | && check_hgt [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 112 + !(!self.check_byr() || !self.check_iyr() || !self.check_eyr() || !check_hgt) [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 112 + self.check_byr() && self.check_iyr() && self.check_eyr() && check_hgt [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> day04/src/main.rs:112:9 [INFO] [stdout] | [INFO] [stdout] 112 | / self.check_byr() [INFO] [stdout] 113 | | && self.check_iyr() [INFO] [stdout] 114 | | && self.check_eyr() [INFO] [stdout] 115 | | && check_hgt [INFO] [stdout] ... | [INFO] [stdout] 118 | | && check_ecl [INFO] [stdout] 119 | | && check_pid [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 117 - && check_hcl [INFO] [stdout] 118 - && check_ecl [INFO] [stdout] 119 - && check_pid [INFO] [stdout] 112 + !(!self.check_byr() || !self.check_iyr() || !self.check_eyr() || !check_hgt || !check_hcl || !check_ecl || !check_pid) [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 117 - && check_hcl [INFO] [stdout] 118 - && check_ecl [INFO] [stdout] 119 - && check_pid [INFO] [stdout] 112 + self.check_byr() && self.check_iyr() && self.check_eyr() && check_hgt && check_hcl && check_ecl && check_pid [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> day04/src/main.rs:112:9 [INFO] [stdout] | [INFO] [stdout] 112 | / self.check_byr() [INFO] [stdout] 113 | | && self.check_iyr() [INFO] [stdout] 114 | | && self.check_eyr() [INFO] [stdout] 115 | | && check_hgt [INFO] [stdout] 116 | | && check_hgt [INFO] [stdout] 117 | | && check_hcl [INFO] [stdout] 118 | | && check_ecl [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 117 - && check_hcl [INFO] [stdout] 118 - && check_ecl [INFO] [stdout] 112 + !(!self.check_byr() || !self.check_iyr() || !self.check_eyr() || !check_hgt || !check_hcl || !check_ecl) [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 117 - && check_hcl [INFO] [stdout] 118 - && check_ecl [INFO] [stdout] 112 + self.check_byr() && self.check_iyr() && self.check_eyr() && check_hgt && check_hcl && check_ecl [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> day04/src/main.rs:112:9 [INFO] [stdout] | [INFO] [stdout] 112 | / self.check_byr() [INFO] [stdout] 113 | | && self.check_iyr() [INFO] [stdout] 114 | | && self.check_eyr() [INFO] [stdout] 115 | | && check_hgt [INFO] [stdout] 116 | | && check_hgt [INFO] [stdout] 117 | | && check_hcl [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 117 - && check_hcl [INFO] [stdout] 112 + !(!self.check_byr() || !self.check_iyr() || !self.check_eyr() || !check_hgt || !check_hcl) [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 117 - && check_hcl [INFO] [stdout] 112 + self.check_byr() && self.check_iyr() && self.check_eyr() && check_hgt && check_hcl [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> day04/src/main.rs:112:9 [INFO] [stdout] | [INFO] [stdout] 112 | / self.check_byr() [INFO] [stdout] 113 | | && self.check_iyr() [INFO] [stdout] 114 | | && self.check_eyr() [INFO] [stdout] 115 | | && check_hgt [INFO] [stdout] 116 | | && check_hgt [INFO] [stdout] | |________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 112 + !(!self.check_byr() || !self.check_iyr() || !self.check_eyr() || !check_hgt) [INFO] [stdout] | [INFO] [stdout] 112 - self.check_byr() [INFO] [stdout] 113 - && self.check_iyr() [INFO] [stdout] 114 - && self.check_eyr() [INFO] [stdout] 115 - && check_hgt [INFO] [stdout] 116 - && check_hgt [INFO] [stdout] 112 + self.check_byr() && self.check_iyr() && self.check_eyr() && check_hgt [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> day08/src/main.rs:107:27 [INFO] [stdout] | [INFO] [stdout] 107 | fn resolve_complex(input: &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] 107 ~ fn resolve_complex(input: &[Operation]) -> usize { [INFO] [stdout] 108 | for (i, op) in input.iter().enumerate() { [INFO] [stdout] 109 | let program = if let Operation::Jmp(val) = *op { [INFO] [stdout] 110 ~ let mut program = input.to_owned(); [INFO] [stdout] 111 | program[i] = Operation::Nop(val); [INFO] [stdout] 112 | program [INFO] [stdout] 113 | } else if let Operation::Nop(val) = *op { [INFO] [stdout] 114 ~ let mut program = input.to_owned(); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> day04/src/main.rs:181:26 [INFO] [stdout] | [INFO] [stdout] 181 | fn resolve_simple(input: &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] 181 - fn resolve_simple(input: &Vec) -> usize { [INFO] [stdout] 181 + fn resolve_simple(input: &[Passport]) -> usize { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> day04/src/main.rs:188:27 [INFO] [stdout] | [INFO] [stdout] 188 | fn resolve_complex(input: &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] help: change this to [INFO] [stdout] | [INFO] [stdout] 188 - fn resolve_complex(input: &Vec) -> usize { [INFO] [stdout] 188 + fn resolve_complex(input: &[Passport]) -> usize { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> day04/src/main.rs:181:26 [INFO] [stdout] | [INFO] [stdout] 181 | fn resolve_simple(input: &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] 181 - fn resolve_simple(input: &Vec) -> usize { [INFO] [stdout] 181 + fn resolve_simple(input: &[Passport]) -> usize { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> day04/src/main.rs:188:27 [INFO] [stdout] | [INFO] [stdout] 188 | fn resolve_complex(input: &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] help: change this to [INFO] [stdout] | [INFO] [stdout] 188 - fn resolve_complex(input: &Vec) -> usize { [INFO] [stdout] 188 + fn resolve_complex(input: &[Passport]) -> usize { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> day13/src/main.rs:40:9 [INFO] [stdout] | [INFO] [stdout] 40 | / if let Some(y) = maybe_id { [INFO] [stdout] 41 | | if ids [INFO] [stdout] 42 | | .iter() [INFO] [stdout] 43 | | .filter_map(|id| *id) [INFO] [stdout] ... | [INFO] [stdout] 49 | | } [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] 40 ~ if let Some(y) = maybe_id [INFO] [stdout] 41 ~ && ids [INFO] [stdout] 42 | .iter() [INFO] [stdout] ... [INFO] [stdout] 47 | return false; [INFO] [stdout] 48 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `Iterator::find` [INFO] [stdout] --> day13/src/main.rs:86:5 [INFO] [stdout] | [INFO] [stdout] 86 | / for i in 1..m { [INFO] [stdout] 87 | | //eprintln!("{x} * {i} = {}", (x * i).rem_euclid(m)); [INFO] [stdout] 88 | | if (x * i).rem_euclid(m) == 1 { [INFO] [stdout] 89 | | return Some(i); [INFO] [stdout] ... | [INFO] [stdout] 92 | | None [INFO] [stdout] | |________^ help: replace with an iterator: `(1..m).find(|&i| (x * i).rem_euclid(m) == 1)` [INFO] [stdout] | [INFO] [stdout] = note: you may need to dereference some variables [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_find [INFO] [stdout] = note: `#[warn(clippy::manual_find)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> derive_from_char/src/fromchar.rs:15:22 [INFO] [stdout] | [INFO] [stdout] 15 | .map(|variant| parse_variant(variant)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `parse_variant` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] = note: `#[warn(clippy::redundant_closure)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `proc_macro2::TokenStream` [INFO] [stdout] --> derive_from_char/src/lib.rs:19:31 [INFO] [stdout] | [INFO] [stdout] 19 | to_compile_error(err, dummy.into()).into() [INFO] [stdout] | ^^^^^^^^^^^^ help: consider removing `.into()`: `dummy` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] = note: `#[warn(clippy::useless_conversion)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this operation has no effect [INFO] [stdout] --> day17/src/pocket_3d.rs:13:18 [INFO] [stdout] | [INFO] [stdout] 13 | let x = (val / 1 % 3) - 1; [INFO] [stdout] | ^^^^^^^ help: consider reducing it to: `val` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stdout] = note: `#[warn(clippy::identity_op)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this operation has no effect [INFO] [stdout] --> day17/src/pocket_3d.rs:38:27 [INFO] [stdout] | [INFO] [stdout] 38 | cubes[0 + padding][y + padding][x + padding] = Cube::Active; [INFO] [stdout] | ^^^^^^^^^^^ help: consider reducing it to: `padding` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` has identical blocks [INFO] [stdout] --> day17/src/pocket_3d.rs:71:21 [INFO] [stdout] | [INFO] [stdout] 71 | / { [INFO] [stdout] 72 | | *cube = Cube::Active; [INFO] [stdout] 73 | | } else if self.cubes[z][y][x] == Cube::Inactive && neighbor_count == 3 { [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] note: same as this [INFO] [stdout] --> day17/src/pocket_3d.rs:73:92 [INFO] [stdout] | [INFO] [stdout] 73 | } else if self.cubes[z][y][x] == Cube::Inactive && neighbor_count == 3 { [INFO] [stdout] | ____________________________________________________________________________________________^ [INFO] [stdout] 74 | | *cube = Cube::Active; [INFO] [stdout] 75 | | } [INFO] [stdout] | |_____________________^ [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#if_same_then_else [INFO] [stdout] = note: `#[warn(clippy::if_same_then_else)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this operation has no effect [INFO] [stdout] --> day17/src/pocket_4d.rs:13:18 [INFO] [stdout] | [INFO] [stdout] 13 | let x = (val / 1 % 3) - 1; [INFO] [stdout] | ^^^^^^^ help: consider reducing it to: `val` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this operation has no effect [INFO] [stdout] --> day17/src/pocket_4d.rs:43:27 [INFO] [stdout] | [INFO] [stdout] 43 | cubes[0 + padding][0 + padding][y + padding][x + padding] = Cube::Active; [INFO] [stdout] | ^^^^^^^^^^^ help: consider reducing it to: `padding` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this operation has no effect [INFO] [stdout] --> day17/src/pocket_4d.rs:43:40 [INFO] [stdout] | [INFO] [stdout] 43 | cubes[0 + padding][0 + padding][y + padding][x + padding] = Cube::Active; [INFO] [stdout] | ^^^^^^^^^^^ help: consider reducing it to: `padding` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` has identical blocks [INFO] [stdout] --> day17/src/pocket_4d.rs:83:25 [INFO] [stdout] | [INFO] [stdout] 83 | / { [INFO] [stdout] 84 | | *cube = Cube::Active; [INFO] [stdout] 85 | | } else if self.cubes[w][z][y][x] == Cube::Inactive && neighbor_count == 3 { [INFO] [stdout] | |_________________________^ [INFO] [stdout] | [INFO] [stdout] note: same as this [INFO] [stdout] --> day17/src/pocket_4d.rs:85:99 [INFO] [stdout] | [INFO] [stdout] 85 | } else if self.cubes[w][z][y][x] == Cube::Inactive && neighbor_count == 3 { [INFO] [stdout] | ___________________________________________________________________________________________________^ [INFO] [stdout] 86 | | *cube = Cube::Active; [INFO] [stdout] 87 | | } [INFO] [stdout] | |_________________________^ [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#if_same_then_else [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this operation has no effect [INFO] [stdout] --> day17/src/pocket_3d.rs:13:18 [INFO] [stdout] | [INFO] [stdout] 13 | let x = (val / 1 % 3) - 1; [INFO] [stdout] | ^^^^^^^ help: consider reducing it to: `val` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stdout] = note: `#[warn(clippy::identity_op)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this operation has no effect [INFO] [stdout] --> day17/src/pocket_3d.rs:38:27 [INFO] [stdout] | [INFO] [stdout] 38 | cubes[0 + padding][y + padding][x + padding] = Cube::Active; [INFO] [stdout] | ^^^^^^^^^^^ help: consider reducing it to: `padding` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` has identical blocks [INFO] [stdout] --> day17/src/pocket_3d.rs:71:21 [INFO] [stdout] | [INFO] [stdout] 71 | / { [INFO] [stdout] 72 | | *cube = Cube::Active; [INFO] [stdout] 73 | | } else if self.cubes[z][y][x] == Cube::Inactive && neighbor_count == 3 { [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] note: same as this [INFO] [stdout] --> day17/src/pocket_3d.rs:73:92 [INFO] [stdout] | [INFO] [stdout] 73 | } else if self.cubes[z][y][x] == Cube::Inactive && neighbor_count == 3 { [INFO] [stdout] | ____________________________________________________________________________________________^ [INFO] [stdout] 74 | | *cube = Cube::Active; [INFO] [stdout] 75 | | } [INFO] [stdout] | |_____________________^ [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#if_same_then_else [INFO] [stdout] = note: `#[warn(clippy::if_same_then_else)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this operation has no effect [INFO] [stdout] --> day17/src/pocket_4d.rs:13:18 [INFO] [stdout] | [INFO] [stdout] 13 | let x = (val / 1 % 3) - 1; [INFO] [stdout] | ^^^^^^^ help: consider reducing it to: `val` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this operation has no effect [INFO] [stdout] --> day17/src/pocket_4d.rs:43:27 [INFO] [stdout] | [INFO] [stdout] 43 | cubes[0 + padding][0 + padding][y + padding][x + padding] = Cube::Active; [INFO] [stdout] | ^^^^^^^^^^^ help: consider reducing it to: `padding` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this operation has no effect [INFO] [stdout] --> day17/src/pocket_4d.rs:43:40 [INFO] [stdout] | [INFO] [stdout] 43 | cubes[0 + padding][0 + padding][y + padding][x + padding] = Cube::Active; [INFO] [stdout] | ^^^^^^^^^^^ help: consider reducing it to: `padding` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` has identical blocks [INFO] [stdout] --> day17/src/pocket_4d.rs:83:25 [INFO] [stdout] | [INFO] [stdout] 83 | / { [INFO] [stdout] 84 | | *cube = Cube::Active; [INFO] [stdout] 85 | | } else if self.cubes[w][z][y][x] == Cube::Inactive && neighbor_count == 3 { [INFO] [stdout] | |_________________________^ [INFO] [stdout] | [INFO] [stdout] note: same as this [INFO] [stdout] --> day17/src/pocket_4d.rs:85:99 [INFO] [stdout] | [INFO] [stdout] 85 | } else if self.cubes[w][z][y][x] == Cube::Inactive && neighbor_count == 3 { [INFO] [stdout] | ___________________________________________________________________________________________________^ [INFO] [stdout] 86 | | *cube = Cube::Active; [INFO] [stdout] 87 | | } [INFO] [stdout] | |_________________________^ [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#if_same_then_else [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 8.27s [INFO] running `Command { std: "docker" "inspect" "1809ffecab17963f5157c9592bd1a57cb1adcc42ccdbe0df474be885f920a424", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "1809ffecab17963f5157c9592bd1a57cb1adcc42ccdbe0df474be885f920a424", kill_on_drop: false }` [INFO] [stdout] 1809ffecab17963f5157c9592bd1a57cb1adcc42ccdbe0df474be885f920a424