[INFO] cloning repository https://github.com/jez/as-tree [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/jez/as-tree" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fjez%2Fas-tree", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fjez%2Fas-tree'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 0036c20f66795774eb9cda3ccbae6ca1e1c19444 [INFO] linting jez/as-tree against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fjez%2Fas-tree" "/workspace/builds/worker-1-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-1-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/jez/as-tree [INFO] finished tweaking git repo https://github.com/jez/as-tree [INFO] tweaked toml for git repo https://github.com/jez/as-tree written to /workspace/builds/worker-1-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/jez/as-tree 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/jez/as-tree 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] warning: unused manifest key: raze [INFO] [stderr] Updating crates.io index [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded lscolors v0.7.0 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-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] e69a83ec1b68f2df180f975650de23fd84ed3ce5fc33b0b701a2ad4a6d1eefd1 [INFO] running `Command { std: "docker" "start" "-a" "e69a83ec1b68f2df180f975650de23fd84ed3ce5fc33b0b701a2ad4a6d1eefd1", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "e69a83ec1b68f2df180f975650de23fd84ed3ce5fc33b0b701a2ad4a6d1eefd1", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "e69a83ec1b68f2df180f975650de23fd84ed3ce5fc33b0b701a2ad4a6d1eefd1", kill_on_drop: false }` [INFO] [stdout] e69a83ec1b68f2df180f975650de23fd84ed3ce5fc33b0b701a2ad4a6d1eefd1 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-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] b4b74a7ff1986d006baf89df5217415b68e6faf016434fbc970c297cd0d595d7 [INFO] running `Command { std: "docker" "start" "-a" "b4b74a7ff1986d006baf89df5217415b68e6faf016434fbc970c297cd0d595d7", kill_on_drop: false }` [INFO] [stderr] warning: unused manifest key: raze [INFO] [stderr] Compiling libc v0.2.70 [INFO] [stderr] Checking lscolors v0.7.0 [INFO] [stderr] Checking atty v0.2.14 [INFO] [stderr] Checking as-tree v0.12.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: this `impl` can be derived [INFO] [stdout] --> src/options.rs:27:1 [INFO] [stdout] | [INFO] [stdout] 27 | / impl Default for Colorize { [INFO] [stdout] 28 | | fn default() -> Self { [INFO] [stdout] 29 | | Colorize::Auto [INFO] [stdout] 30 | | } [INFO] [stdout] 31 | | } [INFO] [stdout] | |_^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derivable_impls [INFO] [stdout] = note: `#[warn(clippy::derivable_impls)]` on by default [INFO] [stdout] help: replace the manual implementation with a derive attribute and mark the default variant [INFO] [stdout] | [INFO] [stdout] 8 + #[derive(Default)] [INFO] [stdout] 9 | pub enum Colorize { [INFO] [stdout] 10 | Always, [INFO] [stdout] 11 ~ #[default] [INFO] [stdout] 12 ~ Auto, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `impl` can be derived [INFO] [stdout] --> src/options.rs:27:1 [INFO] [stdout] | [INFO] [stdout] 27 | / impl Default for Colorize { [INFO] [stdout] 28 | | fn default() -> Self { [INFO] [stdout] 29 | | Colorize::Auto [INFO] [stdout] 30 | | } [INFO] [stdout] 31 | | } [INFO] [stdout] | |_^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derivable_impls [INFO] [stdout] = note: `#[warn(clippy::derivable_impls)]` on by default [INFO] [stdout] help: replace the manual implementation with a derive attribute and mark the default variant [INFO] [stdout] | [INFO] [stdout] 8 + #[derive(Default)] [INFO] [stdout] 9 | pub enum Colorize { [INFO] [stdout] 10 | Always, [INFO] [stdout] 11 ~ #[default] [INFO] [stdout] 12 ~ Auto, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the borrowed expression implements the required traits [INFO] [stdout] --> src/main.rs:22:25 [INFO] [stdout] | [INFO] [stdout] 22 | .style_for_path(&path) [INFO] [stdout] | ^^^^^ help: change this to: `path` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] = note: `#[warn(clippy::needless_borrows_for_generic_args)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the borrowed expression implements the required traits [INFO] [stdout] --> src/main.rs:22:25 [INFO] [stdout] | [INFO] [stdout] 22 | .style_for_path(&path) [INFO] [stdout] | ^^^^^ help: change this to: `path` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] = note: `#[warn(clippy::needless_borrows_for_generic_args)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: use of `or_insert_with` to construct default value [INFO] [stdout] --> src/main.rs:38:18 [INFO] [stdout] | [INFO] [stdout] 38 | .or_insert_with(PathTrie::default); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `or_default()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unwrap_or_default [INFO] [stdout] = note: `#[warn(clippy::unwrap_or_default)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/main.rs:73:32 [INFO] [stdout] | [INFO] [stdout] 73 | let should_print = (contains_singleton_dir && !join_with_parent) [INFO] [stdout] | ________________________________^ [INFO] [stdout] 74 | | || !contains_singleton_dir [INFO] [stdout] 75 | | || !full_path; [INFO] [stdout] | |_____________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 73 - let should_print = (contains_singleton_dir && !join_with_parent) [INFO] [stdout] 74 - || !contains_singleton_dir [INFO] [stdout] 75 - || !full_path; [INFO] [stdout] 73 + let should_print = !(contains_singleton_dir && join_with_parent && full_path); [INFO] [stdout] | [INFO] [stdout] 73 - let should_print = (contains_singleton_dir && !join_with_parent) [INFO] [stdout] 74 - || !contains_singleton_dir [INFO] [stdout] 75 - || !full_path; [INFO] [stdout] 73 + let should_print = !contains_singleton_dir || !join_with_parent || !full_path; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/main.rs:73:32 [INFO] [stdout] | [INFO] [stdout] 73 | let should_print = (contains_singleton_dir && !join_with_parent) [INFO] [stdout] | ________________________________^ [INFO] [stdout] 74 | | || !contains_singleton_dir [INFO] [stdout] | |__________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 73 - let should_print = (contains_singleton_dir && !join_with_parent) [INFO] [stdout] 74 - || !contains_singleton_dir [INFO] [stdout] 73 + let should_print = !(contains_singleton_dir && join_with_parent) [INFO] [stdout] | [INFO] [stdout] 73 - let should_print = (contains_singleton_dir && !join_with_parent) [INFO] [stdout] 74 - || !contains_singleton_dir [INFO] [stdout] 73 + let should_print = !contains_singleton_dir || !join_with_parent [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/main.rs:56:45 [INFO] [stdout] | [INFO] [stdout] 56 | let style = ansi_style_for_path(&lscolors, ¤t_path); [INFO] [stdout] | ^^^^^^^^^ help: change this to: `lscolors` [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: use of `or_insert_with` to construct default value [INFO] [stdout] --> src/main.rs:38:18 [INFO] [stdout] | [INFO] [stdout] 38 | .or_insert_with(PathTrie::default); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `or_default()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unwrap_or_default [INFO] [stdout] = note: `#[warn(clippy::unwrap_or_default)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/main.rs:73:32 [INFO] [stdout] | [INFO] [stdout] 73 | let should_print = (contains_singleton_dir && !join_with_parent) [INFO] [stdout] | ________________________________^ [INFO] [stdout] 74 | | || !contains_singleton_dir [INFO] [stdout] 75 | | || !full_path; [INFO] [stdout] | |_____________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 73 - let should_print = (contains_singleton_dir && !join_with_parent) [INFO] [stdout] 74 - || !contains_singleton_dir [INFO] [stdout] 75 - || !full_path; [INFO] [stdout] 73 + let should_print = !(contains_singleton_dir && join_with_parent && full_path); [INFO] [stdout] | [INFO] [stdout] 73 - let should_print = (contains_singleton_dir && !join_with_parent) [INFO] [stdout] 74 - || !contains_singleton_dir [INFO] [stdout] 75 - || !full_path; [INFO] [stdout] 73 + let should_print = !contains_singleton_dir || !join_with_parent || !full_path; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this creates an owned instance just for comparison [INFO] [stdout] --> src/main.rs:81:68 [INFO] [stdout] | [INFO] [stdout] 81 | let joiner = if full_path || top || parent_path == PathBuf::from("/") { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: try: `*"/"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cmp_owned [INFO] [stdout] = note: `#[warn(clippy::cmp_owned)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/main.rs:73:32 [INFO] [stdout] | [INFO] [stdout] 73 | let should_print = (contains_singleton_dir && !join_with_parent) [INFO] [stdout] | ________________________________^ [INFO] [stdout] 74 | | || !contains_singleton_dir [INFO] [stdout] | |__________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 73 - let should_print = (contains_singleton_dir && !join_with_parent) [INFO] [stdout] 74 - || !contains_singleton_dir [INFO] [stdout] 73 + let should_print = !(contains_singleton_dir && join_with_parent) [INFO] [stdout] | [INFO] [stdout] 73 - let should_print = (contains_singleton_dir && !join_with_parent) [INFO] [stdout] 74 - || !contains_singleton_dir [INFO] [stdout] 73 + let should_print = !contains_singleton_dir || !join_with_parent [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/main.rs:56:45 [INFO] [stdout] | [INFO] [stdout] 56 | let style = ansi_style_for_path(&lscolors, ¤t_path); [INFO] [stdout] | ^^^^^^^^^ help: change this to: `lscolors` [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/main.rs:124:45 [INFO] [stdout] | [INFO] [stdout] 124 | let style = ansi_style_for_path(&lscolors, ¤t_path); [INFO] [stdout] | ^^^^^^^^^ help: change this to: `lscolors` [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 creates an owned instance just for comparison [INFO] [stdout] --> src/main.rs:81:68 [INFO] [stdout] | [INFO] [stdout] 81 | let joiner = if full_path || top || parent_path == PathBuf::from("/") { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: try: `*"/"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cmp_owned [INFO] [stdout] = note: `#[warn(clippy::cmp_owned)]` 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/main.rs:132:13 [INFO] [stdout] | [INFO] [stdout] 132 | &lscolors, [INFO] [stdout] | ^^^^^^^^^ help: change this to: `lscolors` [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: `filter_map()` will run forever if the iterator repeatedly produces an `Err` [INFO] [stdout] --> src/main.rs:142:35 [INFO] [stdout] | [INFO] [stdout] 142 | for path_buf in input.lines().filter_map(Result::ok).map(PathBuf::from) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `map_while(Result::ok)` [INFO] [stdout] | [INFO] [stdout] note: this expression returning a `std::io::Lines` may produce an infinite number of `Err` in case of a read error [INFO] [stdout] --> src/main.rs:142:21 [INFO] [stdout] | [INFO] [stdout] 142 | for path_buf in input.lines().filter_map(Result::ok).map(PathBuf::from) { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#lines_filter_map_ok [INFO] [stdout] = note: `#[warn(clippy::lines_filter_map_ok)]` 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/main.rs:124:45 [INFO] [stdout] | [INFO] [stdout] 124 | let style = ansi_style_for_path(&lscolors, ¤t_path); [INFO] [stdout] | ^^^^^^^^^ help: change this to: `lscolors` [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/main.rs:132:13 [INFO] [stdout] | [INFO] [stdout] 132 | &lscolors, [INFO] [stdout] | ^^^^^^^^^ help: change this to: `lscolors` [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: `filter_map()` will run forever if the iterator repeatedly produces an `Err` [INFO] [stdout] --> src/main.rs:142:35 [INFO] [stdout] | [INFO] [stdout] 142 | for path_buf in input.lines().filter_map(Result::ok).map(PathBuf::from) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `map_while(Result::ok)` [INFO] [stdout] | [INFO] [stdout] note: this expression returning a `std::io::Lines` may produce an infinite number of `Err` in case of a read error [INFO] [stdout] --> src/main.rs:142:21 [INFO] [stdout] | [INFO] [stdout] 142 | for path_buf in input.lines().filter_map(Result::ok).map(PathBuf::from) { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#lines_filter_map_ok [INFO] [stdout] = note: `#[warn(clippy::lines_filter_map_ok)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 1.27s [INFO] running `Command { std: "docker" "inspect" "b4b74a7ff1986d006baf89df5217415b68e6faf016434fbc970c297cd0d595d7", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "b4b74a7ff1986d006baf89df5217415b68e6faf016434fbc970c297cd0d595d7", kill_on_drop: false }` [INFO] [stdout] b4b74a7ff1986d006baf89df5217415b68e6faf016434fbc970c297cd0d595d7