[INFO] cloning repository https://github.com/Ramla-I/trusted_linked_list [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/Ramla-I/trusted_linked_list" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FRamla-I%2Ftrusted_linked_list", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FRamla-I%2Ftrusted_linked_list'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] fd37b7815ac5423110adfd111630daf7806f40d2 [INFO] linting Ramla-I/trusted_linked_list against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FRamla-I%2Ftrusted_linked_list" "/workspace/builds/worker-4-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-4-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/Ramla-I/trusted_linked_list [INFO] finished tweaking git repo https://github.com/Ramla-I/trusted_linked_list [INFO] tweaked toml for git repo https://github.com/Ramla-I/trusted_linked_list written to /workspace/builds/worker-4-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/Ramla-I/trusted_linked_list 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/Ramla-I/trusted_linked_list 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] Updating crates.io index [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded prusti-contracts-proc-macros v0.1.2 [INFO] [stderr] Downloaded prusti-contracts v0.1.2 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+nightly" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 9f47d8506f10789df7b89372530cefe4fa4d77d38b73a454723e3b61114d67f7 [INFO] running `Command { std: "docker" "start" "-a" "9f47d8506f10789df7b89372530cefe4fa4d77d38b73a454723e3b61114d67f7", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "9f47d8506f10789df7b89372530cefe4fa4d77d38b73a454723e3b61114d67f7", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "9f47d8506f10789df7b89372530cefe4fa4d77d38b73a454723e3b61114d67f7", kill_on_drop: false }` [INFO] [stdout] 9f47d8506f10789df7b89372530cefe4fa4d77d38b73a454723e3b61114d67f7 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+nightly" "clippy" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] fde0caf011a009afd7b9fc961eacab39fa7e740e6b8b1ddf2bb280a378a99fca [INFO] running `Command { std: "docker" "start" "-a" "fde0caf011a009afd7b9fc961eacab39fa7e740e6b8b1ddf2bb280a378a99fca", kill_on_drop: false }` [INFO] [stderr] Compiling prusti-contracts-proc-macros v0.1.2 [INFO] [stderr] Checking prusti-contracts v0.1.2 [INFO] [stderr] Checking trusted_linked_list v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unexpected `cfg` condition value: `prusti` [INFO] [stdout] --> src/main.rs:184:16 [INFO] [stdout] | [INFO] [stdout] 184 | #[cfg_attr(feature="prusti", pure)] [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: remove the condition [INFO] [stdout] | [INFO] [stdout] = note: no expected values for `feature` [INFO] [stdout] = help: consider adding `prusti` as a feature in `Cargo.toml` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: `#[warn(unexpected_cfgs)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> src/main.rs:143:13 [INFO] [stdout] | [INFO] [stdout] 143 | elem: elem, [INFO] [stdout] | ^^^^^^^^^^ help: replace it with: `elem` [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: redundant field names in struct initialization [INFO] [stdout] --> src/main.rs:176:13 [INFO] [stdout] | [INFO] [stdout] 176 | elem: elem, [INFO] [stdout] | ^^^^^^^^^^ help: replace it with: `elem` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `node` [INFO] [stdout] --> src/main.rs:43:28 [INFO] [stdout] | [INFO] [stdout] 43 | Link::More(box node) => false, [INFO] [stdout] | ^^^^ help: if this is intentional, prefix it with an underscore: `_node` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `old_len` [INFO] [stdout] --> src/main.rs:141:13 [INFO] [stdout] | [INFO] [stdout] 141 | let old_len = self.head.len(); [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_old_len` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `old_len` [INFO] [stdout] --> src/main.rs:174:13 [INFO] [stdout] | [INFO] [stdout] 174 | let old_len = self.head.len(); [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_old_len` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `is_empty` is never used [INFO] [stdout] --> src/main.rs:40:8 [INFO] [stdout] | [INFO] [stdout] 38 | impl Link { [INFO] [stdout] | --------------- method in this implementation [INFO] [stdout] 39 | #[pure] [INFO] [stdout] 40 | fn is_empty(&self) -> bool { [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 `push_unique` and `overlaps` are never used [INFO] [stdout] --> src/main.rs:169:8 [INFO] [stdout] | [INFO] [stdout] 116 | impl List { [INFO] [stdout] | ----------------------------------------- associated items in this implementation [INFO] [stdout] ... [INFO] [stdout] 169 | fn push_unique(&mut self, elem: T) -> TrustedOption{ [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 185 | pub(crate) fn overlaps(link: &Link, elem: &T) -> bool { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `List` [INFO] [stdout] --> src/main.rs:130:5 [INFO] [stdout] | [INFO] [stdout] 130 | / pub fn new() -> Self { [INFO] [stdout] 131 | | List { [INFO] [stdout] 132 | | head: Link::Empty, [INFO] [stdout] 133 | | } [INFO] [stdout] 134 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] = note: `#[warn(clippy::new_without_default)]` on by default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 116 + impl Default for List { [INFO] [stdout] 117 + fn default() -> Self { [INFO] [stdout] 118 + Self::new() [INFO] [stdout] 119 + } [INFO] [stdout] 120 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `List` has a public `len` method, but no `is_empty` method [INFO] [stdout] --> src/main.rs:119:5 [INFO] [stdout] | [INFO] [stdout] 119 | pub fn len(&self) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_without_is_empty [INFO] [stdout] = note: `#[warn(clippy::len_without_is_empty)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/main.rs:192:21 [INFO] [stdout] | [INFO] [stdout] 192 | false || Self::overlaps(&node.next, elem) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `Self::overlaps(&node.next, elem)` [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: returning the result of a `let` binding from a block [INFO] [stdout] --> src/main.rs:196:9 [INFO] [stdout] | [INFO] [stdout] 186 | / let ret = match link { [INFO] [stdout] 187 | | Link::Empty => false, [INFO] [stdout] 188 | | Link::More(box node) => { [INFO] [stdout] 189 | | if node.elem.overlap(elem) { [INFO] [stdout] ... | [INFO] [stdout] 195 | | }; [INFO] [stdout] | |__________- unnecessary `let` binding [INFO] [stdout] 196 | ret [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_and_return [INFO] [stdout] = note: `#[warn(clippy::let_and_return)]` on by default [INFO] [stdout] help: return the expression directly [INFO] [stdout] | [INFO] [stdout] 186 ~ [INFO] [stdout] 187 ~ match link { [INFO] [stdout] 188 + Link::Empty => false, [INFO] [stdout] 189 + Link::More(box node) => { [INFO] [stdout] 190 + if node.elem.overlap(elem) { [INFO] [stdout] 191 + true [INFO] [stdout] 192 + } else { [INFO] [stdout] 193 + false || Self::overlaps(&node.next, elem) [INFO] [stdout] 194 + } [INFO] [stdout] 195 + } [INFO] [stdout] 196 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `prusti` [INFO] [stdout] --> src/main.rs:184:16 [INFO] [stdout] | [INFO] [stdout] 184 | #[cfg_attr(feature="prusti", pure)] [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: remove the condition [INFO] [stdout] | [INFO] [stdout] = note: no expected values for `feature` [INFO] [stdout] = help: consider adding `prusti` as a feature in `Cargo.toml` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: `#[warn(unexpected_cfgs)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> src/main.rs:143:13 [INFO] [stdout] | [INFO] [stdout] 143 | elem: elem, [INFO] [stdout] | ^^^^^^^^^^ help: replace it with: `elem` [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: redundant field names in struct initialization [INFO] [stdout] --> src/main.rs:176:13 [INFO] [stdout] | [INFO] [stdout] 176 | elem: elem, [INFO] [stdout] | ^^^^^^^^^^ help: replace it with: `elem` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `node` [INFO] [stdout] --> src/main.rs:43:28 [INFO] [stdout] | [INFO] [stdout] 43 | Link::More(box node) => false, [INFO] [stdout] | ^^^^ help: if this is intentional, prefix it with an underscore: `_node` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `old_len` [INFO] [stdout] --> src/main.rs:141:13 [INFO] [stdout] | [INFO] [stdout] 141 | let old_len = self.head.len(); [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_old_len` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `old_len` [INFO] [stdout] --> src/main.rs:174:13 [INFO] [stdout] | [INFO] [stdout] 174 | let old_len = self.head.len(); [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_old_len` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `is_empty` is never used [INFO] [stdout] --> src/main.rs:40:8 [INFO] [stdout] | [INFO] [stdout] 38 | impl Link { [INFO] [stdout] | --------------- method in this implementation [INFO] [stdout] 39 | #[pure] [INFO] [stdout] 40 | fn is_empty(&self) -> bool { [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 `push_unique` and `overlaps` are never used [INFO] [stdout] --> src/main.rs:169:8 [INFO] [stdout] | [INFO] [stdout] 116 | impl List { [INFO] [stdout] | ----------------------------------------- associated items in this implementation [INFO] [stdout] ... [INFO] [stdout] 169 | fn push_unique(&mut self, elem: T) -> TrustedOption{ [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 185 | pub(crate) fn overlaps(link: &Link, elem: &T) -> bool { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `List` [INFO] [stdout] --> src/main.rs:130:5 [INFO] [stdout] | [INFO] [stdout] 130 | / pub fn new() -> Self { [INFO] [stdout] 131 | | List { [INFO] [stdout] 132 | | head: Link::Empty, [INFO] [stdout] 133 | | } [INFO] [stdout] 134 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] = note: `#[warn(clippy::new_without_default)]` on by default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 116 + impl Default for List { [INFO] [stdout] 117 + fn default() -> Self { [INFO] [stdout] 118 + Self::new() [INFO] [stdout] 119 + } [INFO] [stdout] 120 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `List` has a public `len` method, but no `is_empty` method [INFO] [stdout] --> src/main.rs:119:5 [INFO] [stdout] | [INFO] [stdout] 119 | pub fn len(&self) -> usize { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_without_is_empty [INFO] [stdout] = note: `#[warn(clippy::len_without_is_empty)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/main.rs:192:21 [INFO] [stdout] | [INFO] [stdout] 192 | false || Self::overlaps(&node.next, elem) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `Self::overlaps(&node.next, elem)` [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: returning the result of a `let` binding from a block [INFO] [stdout] --> src/main.rs:196:9 [INFO] [stdout] | [INFO] [stdout] 186 | / let ret = match link { [INFO] [stdout] 187 | | Link::Empty => false, [INFO] [stdout] 188 | | Link::More(box node) => { [INFO] [stdout] 189 | | if node.elem.overlap(elem) { [INFO] [stdout] ... | [INFO] [stdout] 195 | | }; [INFO] [stdout] | |__________- unnecessary `let` binding [INFO] [stdout] 196 | ret [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_and_return [INFO] [stdout] = note: `#[warn(clippy::let_and_return)]` on by default [INFO] [stdout] help: return the expression directly [INFO] [stdout] | [INFO] [stdout] 186 ~ [INFO] [stdout] 187 ~ match link { [INFO] [stdout] 188 + Link::Empty => false, [INFO] [stdout] 189 + Link::More(box node) => { [INFO] [stdout] 190 + if node.elem.overlap(elem) { [INFO] [stdout] 191 + true [INFO] [stdout] 192 + } else { [INFO] [stdout] 193 + false || Self::overlaps(&node.next, elem) [INFO] [stdout] 194 + } [INFO] [stdout] 195 + } [INFO] [stdout] 196 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.58s [INFO] running `Command { std: "docker" "inspect" "fde0caf011a009afd7b9fc961eacab39fa7e740e6b8b1ddf2bb280a378a99fca", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "fde0caf011a009afd7b9fc961eacab39fa7e740e6b8b1ddf2bb280a378a99fca", kill_on_drop: false }` [INFO] [stdout] fde0caf011a009afd7b9fc961eacab39fa7e740e6b8b1ddf2bb280a378a99fca