[INFO] cloning repository https://github.com/ernstjanhoek/codewars [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/ernstjanhoek/codewars" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fernstjanhoek%2Fcodewars", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fernstjanhoek%2Fcodewars'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 51df3572a76bccc57634186db275b79afe68f4f3 [INFO] linting ernstjanhoek/codewars against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fernstjanhoek%2Fcodewars" "/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/ernstjanhoek/codewars [INFO] finished tweaking git repo https://github.com/ernstjanhoek/codewars [INFO] tweaked toml for git repo https://github.com/ernstjanhoek/codewars written to /workspace/builds/worker-3-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/ernstjanhoek/codewars 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/ernstjanhoek/codewars already has a lockfile, it will not be regenerated [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded syn v2.0.62 [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] f4c7967cca17a5df571819e14aeae0db1733c73d74493ffcd44d9fcf7f04d4fd [INFO] running `Command { std: "docker" "start" "-a" "f4c7967cca17a5df571819e14aeae0db1733c73d74493ffcd44d9fcf7f04d4fd", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "f4c7967cca17a5df571819e14aeae0db1733c73d74493ffcd44d9fcf7f04d4fd", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "f4c7967cca17a5df571819e14aeae0db1733c73d74493ffcd44d9fcf7f04d4fd", kill_on_drop: false }` [INFO] [stdout] f4c7967cca17a5df571819e14aeae0db1733c73d74493ffcd44d9fcf7f04d4fd [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] 0f7bc3299e8e0108cb68f6cfee8dac0a5ddb5e03ad7a2ead9155f17d05003dd9 [INFO] running `Command { std: "docker" "start" "-a" "0f7bc3299e8e0108cb68f6cfee8dac0a5ddb5e03ad7a2ead9155f17d05003dd9", kill_on_drop: false }` [INFO] [stderr] Checking chrono v0.4.38 [INFO] [stderr] Checking codewars v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> src/path_finder.rs:28:13 [INFO] [stdout] | [INFO] [stdout] 28 | index: index, [INFO] [stdout] | ^^^^^^^^^^^^ help: replace it with: `index` [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 looks like an `else if` but the `else` is missing [INFO] [stdout] --> src/path_finder.rs:91:6 [INFO] [stdout] | [INFO] [stdout] 91 | } if let None = max_n { [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = note: to remove this lint, add the missing `else` or add a new line before the second `if` [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#possible_missing_else [INFO] [stdout] = note: `#[warn(clippy::possible_missing_else)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused macro definition: `compare` [INFO] [stdout] --> src/rgb.rs:5:14 [INFO] [stdout] | [INFO] [stdout] 5 | macro_rules! compare { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_macros)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> src/path_finder.rs:28:13 [INFO] [stdout] | [INFO] [stdout] 28 | index: index, [INFO] [stdout] | ^^^^^^^^^^^^ help: replace it with: `index` [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 looks like an `else if` but the `else` is missing [INFO] [stdout] --> src/path_finder.rs:91:6 [INFO] [stdout] | [INFO] [stdout] 91 | } if let None = max_n { [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = note: to remove this lint, add the missing `else` or add a new line before the second `if` [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#possible_missing_else [INFO] [stdout] = note: `#[warn(clippy::possible_missing_else)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `person` [INFO] [stdout] --> src/teknonymy.rs:53:19 [INFO] [stdout] | [INFO] [stdout] 53 | if let Some(&(person, layer)) = max_layer_tuple { [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_person` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `init_val` [INFO] [stdout] --> src/sum_dig_nth_term.rs:3:21 [INFO] [stdout] | [INFO] [stdout] 3 | fn sum_dig_nth_term(init_val: u32, pattern: &[u32], nth: usize ) -> u32 { [INFO] [stdout] | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_init_val` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `pattern` [INFO] [stdout] --> src/sum_dig_nth_term.rs:3:36 [INFO] [stdout] | [INFO] [stdout] 3 | fn sum_dig_nth_term(init_val: u32, pattern: &[u32], nth: usize ) -> u32 { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_pattern` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `nth` [INFO] [stdout] --> src/sum_dig_nth_term.rs:3:53 [INFO] [stdout] | [INFO] [stdout] 3 | fn sum_dig_nth_term(init_val: u32, pattern: &[u32], nth: usize ) -> u32 { [INFO] [stdout] | ^^^ help: if this is intentional, prefix it with an underscore: `_nth` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `index` [INFO] [stdout] --> src/temp_maze.rs:105:10 [INFO] [stdout] | [INFO] [stdout] 105 | for (index, point) in out.iter().enumerate() { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_index` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `TimeData` is never constructed [INFO] [stdout] --> src/format_duration.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | struct TimeData { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new`, `derive_from_secs`, and `build_string` are never used [INFO] [stdout] --> src/format_duration.rs:46:8 [INFO] [stdout] | [INFO] [stdout] 45 | impl TimeData { [INFO] [stdout] | ------------- associated items in this implementation [INFO] [stdout] 46 | fn new() -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 56 | fn derive_from_secs(mut self, seconds: u64) -> Self { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 64 | fn build_string(&self) -> String { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Second` is never constructed [INFO] [stdout] --> src/format_duration.rs:106:8 [INFO] [stdout] | [INFO] [stdout] 106 | struct Second { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `to_string` is never used [INFO] [stdout] --> src/format_duration.rs:111:8 [INFO] [stdout] | [INFO] [stdout] 110 | impl Second { [INFO] [stdout] | ----------- method in this implementation [INFO] [stdout] 111 | fn to_string(&self) -> String { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Minute` is never constructed [INFO] [stdout] --> src/format_duration.rs:131:8 [INFO] [stdout] | [INFO] [stdout] 131 | struct Minute { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `to_string` is never used [INFO] [stdout] --> src/format_duration.rs:136:8 [INFO] [stdout] | [INFO] [stdout] 135 | impl Minute { [INFO] [stdout] | ----------- method in this implementation [INFO] [stdout] 136 | fn to_string(&self) -> String { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Hour` is never constructed [INFO] [stdout] --> src/format_duration.rs:156:8 [INFO] [stdout] | [INFO] [stdout] 156 | struct Hour { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `to_string` is never used [INFO] [stdout] --> src/format_duration.rs:161:8 [INFO] [stdout] | [INFO] [stdout] 160 | impl Hour { [INFO] [stdout] | --------- method in this implementation [INFO] [stdout] 161 | fn to_string(&self) -> String{ [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Day` is never constructed [INFO] [stdout] --> src/format_duration.rs:181:8 [INFO] [stdout] | [INFO] [stdout] 181 | struct Day { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `to_string` is never used [INFO] [stdout] --> src/format_duration.rs:186:8 [INFO] [stdout] | [INFO] [stdout] 185 | impl Day { [INFO] [stdout] | -------- method in this implementation [INFO] [stdout] 186 | fn to_string(&self) -> String { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Year` is never constructed [INFO] [stdout] --> src/format_duration.rs:206:8 [INFO] [stdout] | [INFO] [stdout] 206 | struct Year { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `to_string` is never used [INFO] [stdout] --> src/format_duration.rs:211:8 [INFO] [stdout] | [INFO] [stdout] 210 | impl Year { [INFO] [stdout] | --------- method in this implementation [INFO] [stdout] 211 | fn to_string(&self) -> String { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `TimeParts` is never constructed [INFO] [stdout] --> src/format_duration.rs:231:8 [INFO] [stdout] | [INFO] [stdout] 231 | struct TimeParts { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new` and `time_left` are never used [INFO] [stdout] --> src/format_duration.rs:237:8 [INFO] [stdout] | [INFO] [stdout] 236 | impl TimeParts { [INFO] [stdout] | -------------- associated items in this implementation [INFO] [stdout] 237 | fn new(remainder: u64, quotient: u64) -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 244 | fn time_left(&self) -> bool { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `TimeCalculation` is never used [INFO] [stdout] --> src/format_duration.rs:249:7 [INFO] [stdout] | [INFO] [stdout] 249 | trait TimeCalculation { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `format_duration` is never used [INFO] [stdout] --> src/format_duration.rs:260:4 [INFO] [stdout] | [INFO] [stdout] 260 | fn format_duration(seconds: u64) -> String { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Dir` is never used [INFO] [stdout] --> src/path_finder.rs:2:6 [INFO] [stdout] | [INFO] [stdout] 2 | enum Dir { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Point` is never constructed [INFO] [stdout] --> src/path_finder.rs:10:8 [INFO] [stdout] | [INFO] [stdout] 10 | struct Point { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Value` is never used [INFO] [stdout] --> src/path_finder.rs:18:6 [INFO] [stdout] | [INFO] [stdout] 18 | enum Value { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new`, `derive_side`, and `is_checked` are never used [INFO] [stdout] --> src/path_finder.rs:25:8 [INFO] [stdout] | [INFO] [stdout] 24 | impl Point { [INFO] [stdout] | ---------- associated items in this implementation [INFO] [stdout] 25 | fn new(value: Value, index: usize) -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 34 | fn derive_side(mut self, max_n: usize) -> Self { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 55 | fn is_checked(&self) -> bool { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `derive_point_vec` is never used [INFO] [stdout] --> src/path_finder.rs:61:4 [INFO] [stdout] | [INFO] [stdout] 61 | fn derive_point_vec(maze: &str, max_n: usize) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `path_finder` is never used [INFO] [stdout] --> src/path_finder.rs:86:4 [INFO] [stdout] | [INFO] [stdout] 86 | fn path_finder(maze: &str) -> bool { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `find_path_block` is never used [INFO] [stdout] --> src/path_finder.rs:98:4 [INFO] [stdout] | [INFO] [stdout] 98 | fn find_path_block(point_vec: &mut Vec, max_n: usize) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `map_neighbours` is never used [INFO] [stdout] --> src/path_finder.rs:131:4 [INFO] [stdout] | [INFO] [stdout] 131 | fn map_neighbours(slice: &[Point], point_index: usize, n: usize) -> Neighbours { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Neighbours` is never constructed [INFO] [stdout] --> src/path_finder.rs:165:8 [INFO] [stdout] | [INFO] [stdout] 165 | struct Neighbours { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: methods `check_init_neighbours` and `check_neighbours` are never used [INFO] [stdout] --> src/path_finder.rs:171:8 [INFO] [stdout] | [INFO] [stdout] 170 | impl Neighbours { [INFO] [stdout] | --------------- methods in this implementation [INFO] [stdout] 171 | fn check_init_neighbours(&self) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 181 | fn check_neighbours(&self) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `is_enclosing` is never used [INFO] [stdout] --> src/path_finder.rs:192:4 [INFO] [stdout] | [INFO] [stdout] 192 | fn is_enclosing(side1: Dir, side2: Dir) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `range_extraction` is never used [INFO] [stdout] --> src/range_extraction.rs:2:12 [INFO] [stdout] | [INFO] [stdout] 2 | pub fn range_extraction(a: &[i32]) -> String { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `is_consecutive` is never used [INFO] [stdout] --> src/range_extraction.rs:32:8 [INFO] [stdout] | [INFO] [stdout] 32 | fn is_consecutive(a: &i32, b:&i32) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `update_buf` is never used [INFO] [stdout] --> src/range_extraction.rs:36:8 [INFO] [stdout] | [INFO] [stdout] 36 | fn update_buf(old_buf: [Option; 2], num: i32, peek: i32) -> [Option; 2] { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `buf_to_string` is never used [INFO] [stdout] --> src/range_extraction.rs:44:8 [INFO] [stdout] | [INFO] [stdout] 44 | fn buf_to_string(range_buf: &[Option; 2]) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `rgb` is never used [INFO] [stdout] --> src/rgb.rs:1:4 [INFO] [stdout] | [INFO] [stdout] 1 | fn rgb(r: i32, g: i32, b: i32) -> String { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Dir` is never used [INFO] [stdout] --> src/snail.rs:2:6 [INFO] [stdout] | [INFO] [stdout] 2 | enum Dir { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `change` is never used [INFO] [stdout] --> src/snail.rs:11:8 [INFO] [stdout] | [INFO] [stdout] 10 | impl Dir { [INFO] [stdout] | -------- method in this implementation [INFO] [stdout] 11 | fn change(self)-> Self { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `snail` is never used [INFO] [stdout] --> src/snail.rs:21:4 [INFO] [stdout] | [INFO] [stdout] 21 | fn snail(matrix: &[Vec]) -> Vec { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `decrease_n` is never used [INFO] [stdout] --> src/snail.rs:36:4 [INFO] [stdout] | [INFO] [stdout] 36 | fn decrease_n(index: usize, n: usize) -> usize { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `extract_values` is never used [INFO] [stdout] --> src/snail.rs:44:4 [INFO] [stdout] | [INFO] [stdout] 44 | fn extract_values(n: usize, dir: Dir, slice: &[Vec]) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `current`, `max_x`, `max_y`, `min_x`, and `min_y` are never read [INFO] [stdout] --> src/spiralize.rs:4:5 [INFO] [stdout] | [INFO] [stdout] 3 | pub struct PointData { [INFO] [stdout] | --------- fields in this struct [INFO] [stdout] 4 | current: Corner, [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] 5 | max_x: i8, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 6 | max_y: i8, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 7 | min_x: i8, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 8 | min_y: i8, [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new`, `traverse_point`, and `return_next_xy` are never used [INFO] [stdout] --> src/spiralize.rs:12:8 [INFO] [stdout] | [INFO] [stdout] 11 | impl PointData { [INFO] [stdout] | -------------- associated items in this implementation [INFO] [stdout] 12 | fn new(grid_size: i8) -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 22 | fn traverse_point(&mut self, spiral_width: i8, x: i8, y: i8) -> Self { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 67 | fn return_next_xy(&self) -> (i8, i8) { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variants `UpperLeft`, `UpperRight`, `LowerRight`, and `LowerLeft` are never constructed [INFO] [stdout] --> src/spiralize.rs:79:5 [INFO] [stdout] | [INFO] [stdout] 78 | enum Corner { [INFO] [stdout] | ------ variants in this enum [INFO] [stdout] 79 | UpperLeft { x: i8, y: i8 }, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] 80 | UpperRight { x: i8, y: i8 }, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] 81 | LowerRight { x: i8, y: i8 }, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] 82 | LowerLeft { x: i8, y: i8 }, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Corner` has derived impls for the traits `Debug` and `Clone`, but these are intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: methods `traverse` and `return_xy` are never used [INFO] [stdout] --> src/spiralize.rs:87:8 [INFO] [stdout] | [INFO] [stdout] 86 | impl Corner { [INFO] [stdout] | ----------- methods in this implementation [INFO] [stdout] 87 | fn traverse(self, x: i8, y: i8) -> Self { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 95 | fn return_xy(&self) -> (i8, i8) { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `spiralize` is never used [INFO] [stdout] --> src/spiralize.rs:105:4 [INFO] [stdout] | [INFO] [stdout] 105 | fn spiralize(size: usize) -> Vec> { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `sq_in_rect` is never used [INFO] [stdout] --> src/sq_in_rect.rs:1:4 [INFO] [stdout] | [INFO] [stdout] 1 | fn sq_in_rect(lng: i32, wdth: i32) -> Option> { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `testing` is never used [INFO] [stdout] --> src/sq_in_rect.rs:21:4 [INFO] [stdout] | [INFO] [stdout] 21 | fn testing(lng: i32, wdth: i32, exp: Option>) -> () { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `extract` is never used [INFO] [stdout] --> src/tree_by_levels.rs:22:8 [INFO] [stdout] | [INFO] [stdout] 7 | impl Node { [INFO] [stdout] | --------- method in this implementation [INFO] [stdout] ... [INFO] [stdout] 22 | fn extract(&self, mut layer: u32) -> Vec<(u32, u32)> { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `sort` is never used [INFO] [stdout] --> src/tree_by_levels.rs:36:4 [INFO] [stdout] | [INFO] [stdout] 36 | fn sort(mut vec: Vec<(u32, u32)>) -> Vec { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `tree_by_levels` is never used [INFO] [stdout] --> src/tree_by_levels.rs:41:4 [INFO] [stdout] | [INFO] [stdout] 41 | fn tree_by_levels(root: &Node) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `symbol` is never read [INFO] [stdout] --> src/roman_as_num.rs:5:9 [INFO] [stdout] | [INFO] [stdout] 4 | struct RomanNumerical { [INFO] [stdout] | -------------- field in this struct [INFO] [stdout] 5 | pub symbol: char, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `RomanNumerical` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `sum_dig_nth_term` is never used [INFO] [stdout] --> src/sum_dig_nth_term.rs:3:4 [INFO] [stdout] | [INFO] [stdout] 3 | fn sum_dig_nth_term(init_val: u32, pattern: &[u32], nth: usize ) -> u32 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Dir` is never used [INFO] [stdout] --> src/temp_maze.rs:4:6 [INFO] [stdout] | [INFO] [stdout] 4 | enum Dir { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Value` is never used [INFO] [stdout] --> src/temp_maze.rs:14:6 [INFO] [stdout] | [INFO] [stdout] 14 | enum Value { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `from_char` is never used [INFO] [stdout] --> src/temp_maze.rs:20:8 [INFO] [stdout] | [INFO] [stdout] 19 | impl Value { [INFO] [stdout] | ---------- associated function in this implementation [INFO] [stdout] 20 | fn from_char(c: char) -> Self { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Point` is never constructed [INFO] [stdout] --> src/temp_maze.rs:30:8 [INFO] [stdout] | [INFO] [stdout] 30 | struct Point { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new`, `derive_side`, and `checked` are never used [INFO] [stdout] --> src/temp_maze.rs:40:8 [INFO] [stdout] | [INFO] [stdout] 39 | impl Point { [INFO] [stdout] | ---------- associated items in this implementation [INFO] [stdout] 40 | fn new(value: Value, x: usize, y: usize) -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 50 | fn derive_side(mut self, max_n: usize) -> Self { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 66 | fn checked(&self) -> bool { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `path_finder` is never used [INFO] [stdout] --> src/temp_maze.rs:72:4 [INFO] [stdout] | [INFO] [stdout] 72 | fn path_finder(maze: &str) -> bool { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `old_path_finder` is never used [INFO] [stdout] --> src/temp_maze.rs:80:4 [INFO] [stdout] | [INFO] [stdout] 80 | fn old_path_finder(maze: &str) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `is_enclosing` is never used [INFO] [stdout] --> src/temp_maze.rs:114:4 [INFO] [stdout] | [INFO] [stdout] 114 | fn is_enclosing(side1: Dir, side2: Dir) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `.filter_map(..)` can be written more simply using `.filter(..)` [INFO] [stdout] --> src/disemvowel.rs:2:15 [INFO] [stdout] | [INFO] [stdout] 2 | s.chars().filter_map(|value|match value { [INFO] [stdout] | _______________^ [INFO] [stdout] 3 | | 'a'|'e'|'i'|'o'|'u'|'A'|'E'|'I'|'O'|'U' => None, [INFO] [stdout] 4 | | _ => Some(value)}).collect() [INFO] [stdout] | |__________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_filter_map [INFO] [stdout] = note: `#[warn(clippy::unnecessary_filter_map)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: binary comparison to literal `Option::None` [INFO] [stdout] --> src/format_duration.rs:67:12 [INFO] [stdout] | [INFO] [stdout] 67 | if self.day == None && self.hour == None && self.minute == None && self.second == None { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: use `Option::is_none()` instead: `self.day.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none [INFO] [stdout] = note: `#[warn(clippy::partialeq_to_none)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: binary comparison to literal `Option::None` [INFO] [stdout] --> src/format_duration.rs:67:32 [INFO] [stdout] | [INFO] [stdout] 67 | if self.day == None && self.hour == None && self.minute == None && self.second == None { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: use `Option::is_none()` instead: `self.hour.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: binary comparison to literal `Option::None` [INFO] [stdout] --> src/format_duration.rs:67:53 [INFO] [stdout] | [INFO] [stdout] 67 | if self.day == None && self.hour == None && self.minute == None && self.second == None { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ help: use `Option::is_none()` instead: `self.minute.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: binary comparison to literal `Option::None` [INFO] [stdout] --> src/format_duration.rs:67:76 [INFO] [stdout] | [INFO] [stdout] 67 | if self.day == None && self.hour == None && self.minute == None && self.second == None { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ help: use `Option::is_none()` instead: `self.second.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: implementation of inherent method `to_string(&self) -> String` for type `format_duration::Second` [INFO] [stdout] --> src/format_duration.rs:111:5 [INFO] [stdout] | [INFO] [stdout] 111 | / fn to_string(&self) -> String { [INFO] [stdout] 112 | | let mut out = String::new(); [INFO] [stdout] 113 | | out.push_str(&self.amount.to_string()); [INFO] [stdout] 114 | | out.push_str(&" second"); [INFO] [stdout] 115 | | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] 116 | | out [INFO] [stdout] 117 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: implement trait `Display` for type `format_duration::Second` instead [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#inherent_to_string [INFO] [stdout] = note: `#[warn(clippy::inherent_to_string)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:114:22 [INFO] [stdout] | [INFO] [stdout] 114 | out.push_str(&" second"); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `" second"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:115:43 [INFO] [stdout] | [INFO] [stdout] 115 | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] | ^^^^ help: change this to: `"s"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: implementation of inherent method `to_string(&self) -> String` for type `format_duration::Minute` [INFO] [stdout] --> src/format_duration.rs:136:5 [INFO] [stdout] | [INFO] [stdout] 136 | / fn to_string(&self) -> String { [INFO] [stdout] 137 | | let mut out = String::new(); [INFO] [stdout] 138 | | out.push_str(&self.amount.to_string()); [INFO] [stdout] 139 | | out.push_str(&" minute"); [INFO] [stdout] 140 | | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] 141 | | out [INFO] [stdout] 142 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: implement trait `Display` for type `format_duration::Minute` instead [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#inherent_to_string [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:139:22 [INFO] [stdout] | [INFO] [stdout] 139 | out.push_str(&" minute"); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `" minute"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:140:43 [INFO] [stdout] | [INFO] [stdout] 140 | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] | ^^^^ help: change this to: `"s"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: implementation of inherent method `to_string(&self) -> String` for type `format_duration::Hour` [INFO] [stdout] --> src/format_duration.rs:161:5 [INFO] [stdout] | [INFO] [stdout] 161 | / fn to_string(&self) -> String{ [INFO] [stdout] 162 | | let mut out = String::new(); [INFO] [stdout] 163 | | out.push_str(&self.amount.to_string()); [INFO] [stdout] 164 | | out.push_str(&" hour"); [INFO] [stdout] 165 | | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] 166 | | out [INFO] [stdout] 167 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: implement trait `Display` for type `format_duration::Hour` instead [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#inherent_to_string [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:164:22 [INFO] [stdout] | [INFO] [stdout] 164 | out.push_str(&" hour"); [INFO] [stdout] | ^^^^^^^^ help: change this to: `" hour"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:165:43 [INFO] [stdout] | [INFO] [stdout] 165 | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] | ^^^^ help: change this to: `"s"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: implementation of inherent method `to_string(&self) -> String` for type `format_duration::Day` [INFO] [stdout] --> src/format_duration.rs:186:5 [INFO] [stdout] | [INFO] [stdout] 186 | / fn to_string(&self) -> String { [INFO] [stdout] 187 | | let mut out = String::new(); [INFO] [stdout] 188 | | out.push_str(&self.amount.to_string()); [INFO] [stdout] 189 | | out.push_str(&" day"); [INFO] [stdout] 190 | | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] 191 | | out [INFO] [stdout] 192 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: implement trait `Display` for type `format_duration::Day` instead [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#inherent_to_string [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:189:22 [INFO] [stdout] | [INFO] [stdout] 189 | out.push_str(&" day"); [INFO] [stdout] | ^^^^^^^ help: change this to: `" day"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:190:43 [INFO] [stdout] | [INFO] [stdout] 190 | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] | ^^^^ help: change this to: `"s"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: implementation of inherent method `to_string(&self) -> String` for type `format_duration::Year` [INFO] [stdout] --> src/format_duration.rs:211:5 [INFO] [stdout] | [INFO] [stdout] 211 | / fn to_string(&self) -> String { [INFO] [stdout] 212 | | let mut out = String::new(); [INFO] [stdout] 213 | | out.push_str(&self.amount.to_string()); [INFO] [stdout] 214 | | out.push_str(&" year"); [INFO] [stdout] 215 | | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] 216 | | out [INFO] [stdout] 217 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: implement trait `Display` for type `format_duration::Year` instead [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#inherent_to_string [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:214:22 [INFO] [stdout] | [INFO] [stdout] 214 | out.push_str(&" year"); [INFO] [stdout] | ^^^^^^^^ help: change this to: `" year"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:215:43 [INFO] [stdout] | [INFO] [stdout] 215 | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] | ^^^^ help: change this to: `"s"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/increment_string.rs:14:9 [INFO] [stdout] | [INFO] [stdout] 14 | return string; [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] 14 - return string; [INFO] [stdout] 14 + string [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/increment_string.rs:40:9 [INFO] [stdout] | [INFO] [stdout] 40 | return format!("{}{:0>digits$}",str_part, num_string); [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] 40 - return format!("{}{:0>digits$}",str_part, num_string); [INFO] [stdout] 40 + format!("{}{:0>digits$}",str_part, num_string) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `.is_multiple_of()` [INFO] [stdout] --> src/path_finder.rs:42:16 [INFO] [stdout] | [INFO] [stdout] 42 | if (self.index + 1) % max_n == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `(self.index + 1).is_multiple_of(max_n)` [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: manual implementation of `.is_multiple_of()` [INFO] [stdout] --> src/path_finder.rs:45:16 [INFO] [stdout] | [INFO] [stdout] 45 | if self.index % max_n == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `self.index.is_multiple_of(max_n)` [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] [INFO] [stdout] [INFO] [stdout] warning: statement with no effect [INFO] [stdout] --> src/path_finder.rs:76:17 [INFO] [stdout] | [INFO] [stdout] 76 | (); [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#no_effect [INFO] [stdout] = note: `#[warn(clippy::no_effect)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/path_finder.rs:89:58 [INFO] [stdout] | [INFO] [stdout] 89 | let mut point_vec: Vec = derive_point_vec(&maze, max_n); [INFO] [stdout] | ^^^^^ help: change this to: `maze` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `if let .. else` expression looks like `matches!` macro [INFO] [stdout] --> src/path_finder.rs:91:7 [INFO] [stdout] | [INFO] [stdout] 91 | } if let None = max_n { [INFO] [stdout] | _______^ [INFO] [stdout] 92 | | true [INFO] [stdout] 93 | | } else { [INFO] [stdout] 94 | | false [INFO] [stdout] 95 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro [INFO] [stdout] = note: `#[warn(clippy::match_like_matches_macro)]` on by default [INFO] [stdout] help: use `matches!` directly [INFO] [stdout] | [INFO] [stdout] 91 - } if let None = max_n { [INFO] [stdout] 92 - true [INFO] [stdout] 93 - } else { [INFO] [stdout] 94 - false [INFO] [stdout] 95 - } [INFO] [stdout] 91 + } matches!(max_n, None) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant pattern matching, consider using `is_none()` [INFO] [stdout] --> src/path_finder.rs:91:14 [INFO] [stdout] | [INFO] [stdout] 91 | } if let None = max_n { [INFO] [stdout] | -------^^^^-------- help: try: `if max_n.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_pattern_matching [INFO] [stdout] = note: `#[warn(clippy::redundant_pattern_matching)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/path_finder.rs:111:51 [INFO] [stdout] | [INFO] [stdout] 111 | let neighbour_candidates = map_neighbours(&point_vec.as_slice(), point.index, max_n); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: change this to: `point_vec.as_slice()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/path_finder.rs:118:55 [INFO] [stdout] | [INFO] [stdout] 118 | let neighbour_candidates = map_neighbours(&point_vec.as_slice(), point.index, max_n); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: change this to: `point_vec.as_slice()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/path_finder.rs:174:42 [INFO] [stdout] | [INFO] [stdout] 174 | if point.value == Blocked && !point.side.is_some() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: try: `point.side.is_none()` [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: unneeded `return` statement [INFO] [stdout] --> src/path_finder.rs:194:9 [INFO] [stdout] | [INFO] [stdout] 194 | return false [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] 194 - return false [INFO] [stdout] 194 + false [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/path_finder.rs:196:9 [INFO] [stdout] | [INFO] [stdout] 196 | return true [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] 196 - return true [INFO] [stdout] 196 + true [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this if-then-else expression returns a bool literal [INFO] [stdout] --> src/path_finder.rs:193:5 [INFO] [stdout] | [INFO] [stdout] 193 | / if side1 == side2 { [INFO] [stdout] 194 | | return false [INFO] [stdout] 195 | | } else { [INFO] [stdout] 196 | | return true [INFO] [stdout] 197 | | } [INFO] [stdout] | |_____^ help: you can reduce it to: `return side1 != side2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_bool [INFO] [stdout] = note: `#[warn(clippy::needless_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/range_extraction.rs:10:40 [INFO] [stdout] | [INFO] [stdout] 10 | if !is_consecutive(&num, &peek) { [INFO] [stdout] | ^^^^ help: change this to: `num` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/range_extraction.rs:10:46 [INFO] [stdout] | [INFO] [stdout] 10 | if !is_consecutive(&num, &peek) { [INFO] [stdout] | ^^^^^ help: change this to: `peek` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/range_extraction.rs:38:13 [INFO] [stdout] | [INFO] [stdout] 38 | return [Some(num), Some(peek)]; [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] 38 - return [Some(num), Some(peek)]; [INFO] [stdout] 38 + [Some(num), Some(peek)] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/range_extraction.rs:40:13 [INFO] [stdout] | [INFO] [stdout] 40 | return [Some(num), Some(peek)]; [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] 40 - return [Some(num), Some(peek)]; [INFO] [stdout] 40 + [Some(num), Some(peek)] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: clamp-like pattern without using clamp function [INFO] [stdout] --> src/rgb.rs:2:38 [INFO] [stdout] | [INFO] [stdout] 2 | format!("{:0>2X}{:0>2X}{:0>2X}", r.max(0).min(255), g.max(0).min(255), b.max(0).min(255)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: replace with clamp: `r.clamp(0, 255)` [INFO] [stdout] | [INFO] [stdout] = note: clamp will panic if max < min [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_clamp [INFO] [stdout] = note: `#[warn(clippy::manual_clamp)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: clamp-like pattern without using clamp function [INFO] [stdout] --> src/rgb.rs:2:57 [INFO] [stdout] | [INFO] [stdout] 2 | format!("{:0>2X}{:0>2X}{:0>2X}", r.max(0).min(255), g.max(0).min(255), b.max(0).min(255)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: replace with clamp: `g.clamp(0, 255)` [INFO] [stdout] | [INFO] [stdout] = note: clamp will panic if max < min [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_clamp [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: clamp-like pattern without using clamp function [INFO] [stdout] --> src/rgb.rs:2:76 [INFO] [stdout] | [INFO] [stdout] 2 | format!("{:0>2X}{:0>2X}{:0>2X}", r.max(0).min(255), g.max(0).min(255), b.max(0).min(255)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: replace with clamp: `b.clamp(0, 255)` [INFO] [stdout] | [INFO] [stdout] = note: clamp will panic if max < min [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_clamp [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `.is_multiple_of()` [INFO] [stdout] --> src/snail.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | if index % 2 == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace with: `index.is_multiple_of(2)` [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] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/sq_in_rect.rs:21:55 [INFO] [stdout] | [INFO] [stdout] 21 | fn testing(lng: i32, wdth: i32, exp: Option>) -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/teknonymy.rs:25:31 [INFO] [stdout] | [INFO] [stdout] 25 | people_buffer.push_front((&family_tree, 0)); [INFO] [stdout] | ^^^^^^^^^^^^ help: change this to: `family_tree` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/teknonymy.rs:41:73 [INFO] [stdout] | [INFO] [stdout] 41 | family_tree.teknonym = add_generational_steps(layer) + &*parent(&family_tree) + " " + &*of_str; [INFO] [stdout] | ^^^^^^^^^^^^ help: change this to: `family_tree` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `.iter().next()` on an array [INFO] [stdout] --> src/teknonymy.rs:51:27 [INFO] [stdout] | [INFO] [stdout] 51 | let max_layer_tuple = sorted_tree.iter().next(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: try calling: `sorted_tree.first()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_next_slice [INFO] [stdout] = note: `#[warn(clippy::iter_next_slice)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this OR pattern can be rewritten using a range [INFO] [stdout] --> src/greed.rs:17:17 [INFO] [stdout] | [INFO] [stdout] 17 | 2 | 3 | 4 | 5 | 6 => score += u32::from(*num) * 100, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: try: `2..=6` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_range_patterns [INFO] [stdout] = note: `#[warn(clippy::manual_range_patterns)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you seem to want to iterate on a map's values [INFO] [stdout] --> src/greed.rs:23:23 [INFO] [stdout] | [INFO] [stdout] 23 | for (_, count) in &mut counts { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#for_kv_map [INFO] [stdout] = note: `#[warn(clippy::for_kv_map)]` on by default [INFO] [stdout] help: use the corresponding method [INFO] [stdout] | [INFO] [stdout] 23 - for (_, count) in &mut counts { [INFO] [stdout] 23 + for count in counts.values_mut() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/roman_as_num.rs:62:5 [INFO] [stdout] | [INFO] [stdout] 62 | return sum.try_into().unwrap(); [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 sum.try_into().unwrap(); [INFO] [stdout] 62 + sum.try_into().unwrap() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of an assign operation [INFO] [stdout] --> src/dithering.rs:73:9 [INFO] [stdout] | [INFO] [stdout] 73 | pow_two_width = pow_two_width / 2; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `pow_two_width /= 2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern [INFO] [stdout] = note: `#[warn(clippy::assign_op_pattern)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of an assign operation [INFO] [stdout] --> src/dithering.rs:78:9 [INFO] [stdout] | [INFO] [stdout] 78 | pow_two_height = pow_two_height / 2; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `pow_two_height /= 2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary map of the identity function [INFO] [stdout] --> src/temp_maze.rs:81:43 [INFO] [stdout] | [INFO] [stdout] 81 | let char_vec: Vec = maze.chars().map(|c|c).collect(); [INFO] [stdout] | ^^^^^^^^^^ help: remove the call to `map` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_identity [INFO] [stdout] = note: `#[warn(clippy::map_identity)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/temp_maze.rs:120:46 [INFO] [stdout] | [INFO] [stdout] 120 | (N, E) | (E, N) | (W, S) | (S, W) => return false, [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] 120 - (N, E) | (E, N) | (W, S) | (S, W) => return false, [INFO] [stdout] 120 + (N, E) | (E, N) | (W, S) | (S, W) => false, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/temp_maze.rs:121:14 [INFO] [stdout] | [INFO] [stdout] 121 | _ => return true, [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] 121 - _ => return true, [INFO] [stdout] 121 + _ => true, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Chars<'_>` [INFO] [stdout] --> src/group_parenthesis.rs:7:14 [INFO] [stdout] | [INFO] [stdout] 7 | for c in s.chars().into_iter() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `s.chars()` [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: path statement with no effect [INFO] [stdout] --> src/format_duration.rs:32:9 [INFO] [stdout] | [INFO] [stdout] 32 | local_time [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 59 | update_time!(self, time_parts); [INFO] [stdout] | ------------------------------ in this macro invocation [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(path_statements)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] = note: this warning originates in the macro `update_time` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `person` [INFO] [stdout] --> src/teknonymy.rs:53:19 [INFO] [stdout] | [INFO] [stdout] 53 | if let Some(&(person, layer)) = max_layer_tuple { [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_person` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `init_val` [INFO] [stdout] --> src/sum_dig_nth_term.rs:3:21 [INFO] [stdout] | [INFO] [stdout] 3 | fn sum_dig_nth_term(init_val: u32, pattern: &[u32], nth: usize ) -> u32 { [INFO] [stdout] | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_init_val` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `pattern` [INFO] [stdout] --> src/sum_dig_nth_term.rs:3:36 [INFO] [stdout] | [INFO] [stdout] 3 | fn sum_dig_nth_term(init_val: u32, pattern: &[u32], nth: usize ) -> u32 { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_pattern` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `nth` [INFO] [stdout] --> src/sum_dig_nth_term.rs:3:53 [INFO] [stdout] | [INFO] [stdout] 3 | fn sum_dig_nth_term(init_val: u32, pattern: &[u32], nth: usize ) -> u32 { [INFO] [stdout] | ^^^ help: if this is intentional, prefix it with an underscore: `_nth` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `index` [INFO] [stdout] --> src/temp_maze.rs:105:10 [INFO] [stdout] | [INFO] [stdout] 105 | for (index, point) in out.iter().enumerate() { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_index` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `check_init_neighbours` is never used [INFO] [stdout] --> src/path_finder.rs:171:8 [INFO] [stdout] | [INFO] [stdout] 170 | impl Neighbours { [INFO] [stdout] | --------------- method in this implementation [INFO] [stdout] 171 | fn check_init_neighbours(&self) -> Vec { [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 `ERR_MSG` is never used [INFO] [stdout] --> src/move_zeros.rs:21:11 [INFO] [stdout] | [INFO] [stdout] 21 | const ERR_MSG: &str = "\nYour result (left) did not match the expected output (right)"; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `symbol` is never read [INFO] [stdout] --> src/roman_as_num.rs:5:9 [INFO] [stdout] | [INFO] [stdout] 4 | struct RomanNumerical { [INFO] [stdout] | -------------- field in this struct [INFO] [stdout] 5 | pub symbol: char, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `RomanNumerical` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Dir` is never used [INFO] [stdout] --> src/temp_maze.rs:4:6 [INFO] [stdout] | [INFO] [stdout] 4 | enum Dir { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Value` is never used [INFO] [stdout] --> src/temp_maze.rs:14:6 [INFO] [stdout] | [INFO] [stdout] 14 | enum Value { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `from_char` is never used [INFO] [stdout] --> src/temp_maze.rs:20:8 [INFO] [stdout] | [INFO] [stdout] 19 | impl Value { [INFO] [stdout] | ---------- associated function in this implementation [INFO] [stdout] 20 | fn from_char(c: char) -> Self { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Point` is never constructed [INFO] [stdout] --> src/temp_maze.rs:30:8 [INFO] [stdout] | [INFO] [stdout] 30 | struct Point { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new`, `derive_side`, and `checked` are never used [INFO] [stdout] --> src/temp_maze.rs:40:8 [INFO] [stdout] | [INFO] [stdout] 39 | impl Point { [INFO] [stdout] | ---------- associated items in this implementation [INFO] [stdout] 40 | fn new(value: Value, x: usize, y: usize) -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 50 | fn derive_side(mut self, max_n: usize) -> Self { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 66 | fn checked(&self) -> bool { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `old_path_finder` is never used [INFO] [stdout] --> src/temp_maze.rs:80:4 [INFO] [stdout] | [INFO] [stdout] 80 | fn old_path_finder(maze: &str) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `is_enclosing` is never used [INFO] [stdout] --> src/temp_maze.rs:114:4 [INFO] [stdout] | [INFO] [stdout] 114 | fn is_enclosing(side1: Dir, side2: Dir) -> bool { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `.filter_map(..)` can be written more simply using `.filter(..)` [INFO] [stdout] --> src/disemvowel.rs:2:15 [INFO] [stdout] | [INFO] [stdout] 2 | s.chars().filter_map(|value|match value { [INFO] [stdout] | _______________^ [INFO] [stdout] 3 | | 'a'|'e'|'i'|'o'|'u'|'A'|'E'|'I'|'O'|'U' => None, [INFO] [stdout] 4 | | _ => Some(value)}).collect() [INFO] [stdout] | |__________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_filter_map [INFO] [stdout] = note: `#[warn(clippy::unnecessary_filter_map)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: binary comparison to literal `Option::None` [INFO] [stdout] --> src/format_duration.rs:67:12 [INFO] [stdout] | [INFO] [stdout] 67 | if self.day == None && self.hour == None && self.minute == None && self.second == None { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: use `Option::is_none()` instead: `self.day.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none [INFO] [stdout] = note: `#[warn(clippy::partialeq_to_none)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: binary comparison to literal `Option::None` [INFO] [stdout] --> src/format_duration.rs:67:32 [INFO] [stdout] | [INFO] [stdout] 67 | if self.day == None && self.hour == None && self.minute == None && self.second == None { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: use `Option::is_none()` instead: `self.hour.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: binary comparison to literal `Option::None` [INFO] [stdout] --> src/format_duration.rs:67:53 [INFO] [stdout] | [INFO] [stdout] 67 | if self.day == None && self.hour == None && self.minute == None && self.second == None { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ help: use `Option::is_none()` instead: `self.minute.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: binary comparison to literal `Option::None` [INFO] [stdout] --> src/format_duration.rs:67:76 [INFO] [stdout] | [INFO] [stdout] 67 | if self.day == None && self.hour == None && self.minute == None && self.second == None { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ help: use `Option::is_none()` instead: `self.second.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: implementation of inherent method `to_string(&self) -> String` for type `format_duration::Second` [INFO] [stdout] --> src/format_duration.rs:111:5 [INFO] [stdout] | [INFO] [stdout] 111 | / fn to_string(&self) -> String { [INFO] [stdout] 112 | | let mut out = String::new(); [INFO] [stdout] 113 | | out.push_str(&self.amount.to_string()); [INFO] [stdout] 114 | | out.push_str(&" second"); [INFO] [stdout] 115 | | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] 116 | | out [INFO] [stdout] 117 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: implement trait `Display` for type `format_duration::Second` instead [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#inherent_to_string [INFO] [stdout] = note: `#[warn(clippy::inherent_to_string)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:114:22 [INFO] [stdout] | [INFO] [stdout] 114 | out.push_str(&" second"); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `" second"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:115:43 [INFO] [stdout] | [INFO] [stdout] 115 | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] | ^^^^ help: change this to: `"s"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: implementation of inherent method `to_string(&self) -> String` for type `format_duration::Minute` [INFO] [stdout] --> src/format_duration.rs:136:5 [INFO] [stdout] | [INFO] [stdout] 136 | / fn to_string(&self) -> String { [INFO] [stdout] 137 | | let mut out = String::new(); [INFO] [stdout] 138 | | out.push_str(&self.amount.to_string()); [INFO] [stdout] 139 | | out.push_str(&" minute"); [INFO] [stdout] 140 | | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] 141 | | out [INFO] [stdout] 142 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: implement trait `Display` for type `format_duration::Minute` instead [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#inherent_to_string [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:139:22 [INFO] [stdout] | [INFO] [stdout] 139 | out.push_str(&" minute"); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `" minute"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:140:43 [INFO] [stdout] | [INFO] [stdout] 140 | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] | ^^^^ help: change this to: `"s"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: implementation of inherent method `to_string(&self) -> String` for type `format_duration::Hour` [INFO] [stdout] --> src/format_duration.rs:161:5 [INFO] [stdout] | [INFO] [stdout] 161 | / fn to_string(&self) -> String{ [INFO] [stdout] 162 | | let mut out = String::new(); [INFO] [stdout] 163 | | out.push_str(&self.amount.to_string()); [INFO] [stdout] 164 | | out.push_str(&" hour"); [INFO] [stdout] 165 | | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] 166 | | out [INFO] [stdout] 167 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: implement trait `Display` for type `format_duration::Hour` instead [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#inherent_to_string [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:164:22 [INFO] [stdout] | [INFO] [stdout] 164 | out.push_str(&" hour"); [INFO] [stdout] | ^^^^^^^^ help: change this to: `" hour"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:165:43 [INFO] [stdout] | [INFO] [stdout] 165 | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] | ^^^^ help: change this to: `"s"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: implementation of inherent method `to_string(&self) -> String` for type `format_duration::Day` [INFO] [stdout] --> src/format_duration.rs:186:5 [INFO] [stdout] | [INFO] [stdout] 186 | / fn to_string(&self) -> String { [INFO] [stdout] 187 | | let mut out = String::new(); [INFO] [stdout] 188 | | out.push_str(&self.amount.to_string()); [INFO] [stdout] 189 | | out.push_str(&" day"); [INFO] [stdout] 190 | | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] 191 | | out [INFO] [stdout] 192 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: implement trait `Display` for type `format_duration::Day` instead [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#inherent_to_string [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:189:22 [INFO] [stdout] | [INFO] [stdout] 189 | out.push_str(&" day"); [INFO] [stdout] | ^^^^^^^ help: change this to: `" day"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:190:43 [INFO] [stdout] | [INFO] [stdout] 190 | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] | ^^^^ help: change this to: `"s"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: implementation of inherent method `to_string(&self) -> String` for type `format_duration::Year` [INFO] [stdout] --> src/format_duration.rs:211:5 [INFO] [stdout] | [INFO] [stdout] 211 | / fn to_string(&self) -> String { [INFO] [stdout] 212 | | let mut out = String::new(); [INFO] [stdout] 213 | | out.push_str(&self.amount.to_string()); [INFO] [stdout] 214 | | out.push_str(&" year"); [INFO] [stdout] 215 | | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] 216 | | out [INFO] [stdout] 217 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: implement trait `Display` for type `format_duration::Year` instead [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#inherent_to_string [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:214:22 [INFO] [stdout] | [INFO] [stdout] 214 | out.push_str(&" year"); [INFO] [stdout] | ^^^^^^^^ help: change this to: `" year"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/format_duration.rs:215:43 [INFO] [stdout] | [INFO] [stdout] 215 | if self.amount > 1 { out.push_str(&"s"); } [INFO] [stdout] | ^^^^ help: change this to: `"s"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/increment_string.rs:14:9 [INFO] [stdout] | [INFO] [stdout] 14 | return string; [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] 14 - return string; [INFO] [stdout] 14 + string [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/increment_string.rs:40:9 [INFO] [stdout] | [INFO] [stdout] 40 | return format!("{}{:0>digits$}",str_part, num_string); [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] 40 - return format!("{}{:0>digits$}",str_part, num_string); [INFO] [stdout] 40 + format!("{}{:0>digits$}",str_part, num_string) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `.is_multiple_of()` [INFO] [stdout] --> src/path_finder.rs:42:16 [INFO] [stdout] | [INFO] [stdout] 42 | if (self.index + 1) % max_n == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `(self.index + 1).is_multiple_of(max_n)` [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: manual implementation of `.is_multiple_of()` [INFO] [stdout] --> src/path_finder.rs:45:16 [INFO] [stdout] | [INFO] [stdout] 45 | if self.index % max_n == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `self.index.is_multiple_of(max_n)` [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] [INFO] [stdout] [INFO] [stdout] warning: statement with no effect [INFO] [stdout] --> src/path_finder.rs:76:17 [INFO] [stdout] | [INFO] [stdout] 76 | (); [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#no_effect [INFO] [stdout] = note: `#[warn(clippy::no_effect)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/path_finder.rs:89:58 [INFO] [stdout] | [INFO] [stdout] 89 | let mut point_vec: Vec = derive_point_vec(&maze, max_n); [INFO] [stdout] | ^^^^^ help: change this to: `maze` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `if let .. else` expression looks like `matches!` macro [INFO] [stdout] --> src/path_finder.rs:91:7 [INFO] [stdout] | [INFO] [stdout] 91 | } if let None = max_n { [INFO] [stdout] | _______^ [INFO] [stdout] 92 | | true [INFO] [stdout] 93 | | } else { [INFO] [stdout] 94 | | false [INFO] [stdout] 95 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro [INFO] [stdout] = note: `#[warn(clippy::match_like_matches_macro)]` on by default [INFO] [stdout] help: use `matches!` directly [INFO] [stdout] | [INFO] [stdout] 91 - } if let None = max_n { [INFO] [stdout] 92 - true [INFO] [stdout] 93 - } else { [INFO] [stdout] 94 - false [INFO] [stdout] 95 - } [INFO] [stdout] 91 + } matches!(max_n, None) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant pattern matching, consider using `is_none()` [INFO] [stdout] --> src/path_finder.rs:91:14 [INFO] [stdout] | [INFO] [stdout] 91 | } if let None = max_n { [INFO] [stdout] | -------^^^^-------- help: try: `if max_n.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_pattern_matching [INFO] [stdout] = note: `#[warn(clippy::redundant_pattern_matching)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/path_finder.rs:111:51 [INFO] [stdout] | [INFO] [stdout] 111 | let neighbour_candidates = map_neighbours(&point_vec.as_slice(), point.index, max_n); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: change this to: `point_vec.as_slice()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/path_finder.rs:118:55 [INFO] [stdout] | [INFO] [stdout] 118 | let neighbour_candidates = map_neighbours(&point_vec.as_slice(), point.index, max_n); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: change this to: `point_vec.as_slice()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/path_finder.rs:174:42 [INFO] [stdout] | [INFO] [stdout] 174 | if point.value == Blocked && !point.side.is_some() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: try: `point.side.is_none()` [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: unneeded `return` statement [INFO] [stdout] --> src/path_finder.rs:194:9 [INFO] [stdout] | [INFO] [stdout] 194 | return false [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] 194 - return false [INFO] [stdout] 194 + false [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/path_finder.rs:196:9 [INFO] [stdout] | [INFO] [stdout] 196 | return true [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] 196 - return true [INFO] [stdout] 196 + true [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this if-then-else expression returns a bool literal [INFO] [stdout] --> src/path_finder.rs:193:5 [INFO] [stdout] | [INFO] [stdout] 193 | / if side1 == side2 { [INFO] [stdout] 194 | | return false [INFO] [stdout] 195 | | } else { [INFO] [stdout] 196 | | return true [INFO] [stdout] 197 | | } [INFO] [stdout] | |_____^ help: you can reduce it to: `return side1 != side2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_bool [INFO] [stdout] = note: `#[warn(clippy::needless_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/range_extraction.rs:10:40 [INFO] [stdout] | [INFO] [stdout] 10 | if !is_consecutive(&num, &peek) { [INFO] [stdout] | ^^^^ help: change this to: `num` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/range_extraction.rs:10:46 [INFO] [stdout] | [INFO] [stdout] 10 | if !is_consecutive(&num, &peek) { [INFO] [stdout] | ^^^^^ help: change this to: `peek` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/range_extraction.rs:38:13 [INFO] [stdout] | [INFO] [stdout] 38 | return [Some(num), Some(peek)]; [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] 38 - return [Some(num), Some(peek)]; [INFO] [stdout] 38 + [Some(num), Some(peek)] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/range_extraction.rs:40:13 [INFO] [stdout] | [INFO] [stdout] 40 | return [Some(num), Some(peek)]; [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] 40 - return [Some(num), Some(peek)]; [INFO] [stdout] 40 + [Some(num), Some(peek)] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 1.58s [INFO] [stdout] warning: clamp-like pattern without using clamp function [INFO] [stdout] --> src/rgb.rs:2:38 [INFO] [stdout] | [INFO] [stdout] 2 | format!("{:0>2X}{:0>2X}{:0>2X}", r.max(0).min(255), g.max(0).min(255), b.max(0).min(255)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: replace with clamp: `r.clamp(0, 255)` [INFO] [stdout] | [INFO] [stdout] = note: clamp will panic if max < min [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_clamp [INFO] [stdout] = note: `#[warn(clippy::manual_clamp)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: clamp-like pattern without using clamp function [INFO] [stdout] --> src/rgb.rs:2:57 [INFO] [stdout] | [INFO] [stdout] 2 | format!("{:0>2X}{:0>2X}{:0>2X}", r.max(0).min(255), g.max(0).min(255), b.max(0).min(255)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: replace with clamp: `g.clamp(0, 255)` [INFO] [stdout] | [INFO] [stdout] = note: clamp will panic if max < min [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_clamp [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: clamp-like pattern without using clamp function [INFO] [stdout] --> src/rgb.rs:2:76 [INFO] [stdout] | [INFO] [stdout] 2 | format!("{:0>2X}{:0>2X}{:0>2X}", r.max(0).min(255), g.max(0).min(255), b.max(0).min(255)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: replace with clamp: `b.clamp(0, 255)` [INFO] [stdout] | [INFO] [stdout] = note: clamp will panic if max < min [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_clamp [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `.is_multiple_of()` [INFO] [stdout] --> src/snail.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | if index % 2 == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace with: `index.is_multiple_of(2)` [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] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/sq_in_rect.rs:21:55 [INFO] [stdout] | [INFO] [stdout] 21 | fn testing(lng: i32, wdth: i32, exp: Option>) -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/teknonymy.rs:25:31 [INFO] [stdout] | [INFO] [stdout] 25 | people_buffer.push_front((&family_tree, 0)); [INFO] [stdout] | ^^^^^^^^^^^^ help: change this to: `family_tree` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/teknonymy.rs:41:73 [INFO] [stdout] | [INFO] [stdout] 41 | family_tree.teknonym = add_generational_steps(layer) + &*parent(&family_tree) + " " + &*of_str; [INFO] [stdout] | ^^^^^^^^^^^^ help: change this to: `family_tree` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `.iter().next()` on an array [INFO] [stdout] --> src/teknonymy.rs:51:27 [INFO] [stdout] | [INFO] [stdout] 51 | let max_layer_tuple = sorted_tree.iter().next(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: try calling: `sorted_tree.first()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_next_slice [INFO] [stdout] = note: `#[warn(clippy::iter_next_slice)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this OR pattern can be rewritten using a range [INFO] [stdout] --> src/greed.rs:17:17 [INFO] [stdout] | [INFO] [stdout] 17 | 2 | 3 | 4 | 5 | 6 => score += u32::from(*num) * 100, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: try: `2..=6` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_range_patterns [INFO] [stdout] = note: `#[warn(clippy::manual_range_patterns)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you seem to want to iterate on a map's values [INFO] [stdout] --> src/greed.rs:23:23 [INFO] [stdout] | [INFO] [stdout] 23 | for (_, count) in &mut counts { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#for_kv_map [INFO] [stdout] = note: `#[warn(clippy::for_kv_map)]` on by default [INFO] [stdout] help: use the corresponding method [INFO] [stdout] | [INFO] [stdout] 23 - for (_, count) in &mut counts { [INFO] [stdout] 23 + for count in counts.values_mut() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/roman_as_num.rs:62:5 [INFO] [stdout] | [INFO] [stdout] 62 | return sum.try_into().unwrap(); [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 sum.try_into().unwrap(); [INFO] [stdout] 62 + sum.try_into().unwrap() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of an assign operation [INFO] [stdout] --> src/dithering.rs:73:9 [INFO] [stdout] | [INFO] [stdout] 73 | pow_two_width = pow_two_width / 2; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `pow_two_width /= 2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern [INFO] [stdout] = note: `#[warn(clippy::assign_op_pattern)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of an assign operation [INFO] [stdout] --> src/dithering.rs:78:9 [INFO] [stdout] | [INFO] [stdout] 78 | pow_two_height = pow_two_height / 2; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `pow_two_height /= 2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary map of the identity function [INFO] [stdout] --> src/temp_maze.rs:81:43 [INFO] [stdout] | [INFO] [stdout] 81 | let char_vec: Vec = maze.chars().map(|c|c).collect(); [INFO] [stdout] | ^^^^^^^^^^ help: remove the call to `map` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_identity [INFO] [stdout] = note: `#[warn(clippy::map_identity)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/temp_maze.rs:120:46 [INFO] [stdout] | [INFO] [stdout] 120 | (N, E) | (E, N) | (W, S) | (S, W) => return false, [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] 120 - (N, E) | (E, N) | (W, S) | (S, W) => return false, [INFO] [stdout] 120 + (N, E) | (E, N) | (W, S) | (S, W) => false, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/temp_maze.rs:121:14 [INFO] [stdout] | [INFO] [stdout] 121 | _ => return true, [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] 121 - _ => return true, [INFO] [stdout] 121 + _ => true, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `std::str::Chars<'_>` [INFO] [stdout] --> src/group_parenthesis.rs:7:14 [INFO] [stdout] | [INFO] [stdout] 7 | for c in s.chars().into_iter() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into_iter()`: `s.chars()` [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: path statement with no effect [INFO] [stdout] --> src/format_duration.rs:32:9 [INFO] [stdout] | [INFO] [stdout] 32 | local_time [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 59 | update_time!(self, time_parts); [INFO] [stdout] | ------------------------------ in this macro invocation [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(path_statements)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] = note: this warning originates in the macro `update_time` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] running `Command { std: "docker" "inspect" "0f7bc3299e8e0108cb68f6cfee8dac0a5ddb5e03ad7a2ead9155f17d05003dd9", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "0f7bc3299e8e0108cb68f6cfee8dac0a5ddb5e03ad7a2ead9155f17d05003dd9", kill_on_drop: false }` [INFO] [stdout] 0f7bc3299e8e0108cb68f6cfee8dac0a5ddb5e03ad7a2ead9155f17d05003dd9