[INFO] cloning repository https://github.com/xkillx/belajar-rust [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/xkillx/belajar-rust" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fxkillx%2Fbelajar-rust", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fxkillx%2Fbelajar-rust'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] c09fc1cc3e81290b6ab00707163fb2a19b56c603 [INFO] linting xkillx/belajar-rust against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fxkillx%2Fbelajar-rust" "/workspace/builds/worker-7-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-7-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/xkillx/belajar-rust [INFO] finished tweaking git repo https://github.com/xkillx/belajar-rust [INFO] tweaked toml for git repo https://github.com/xkillx/belajar-rust written to /workspace/builds/worker-7-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/xkillx/belajar-rust 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/xkillx/belajar-rust already has a lockfile, it will not be regenerated [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-7-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-7-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] e4b00045b0b25d57a5983772977c36e5596787e8bbca21d1b947ea0d6684cc6f [INFO] running `Command { std: "docker" "start" "-a" "e4b00045b0b25d57a5983772977c36e5596787e8bbca21d1b947ea0d6684cc6f", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "e4b00045b0b25d57a5983772977c36e5596787e8bbca21d1b947ea0d6684cc6f", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "e4b00045b0b25d57a5983772977c36e5596787e8bbca21d1b947ea0d6684cc6f", kill_on_drop: false }` [INFO] [stdout] e4b00045b0b25d57a5983772977c36e5596787e8bbca21d1b947ea0d6684cc6f [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-7-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-7-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] 9a13c0ec2826a63ed623cbdc8ac873c41f02d37949e7bd18a5ada417775947c6 [INFO] running `Command { std: "docker" "start" "-a" "9a13c0ec2826a63ed623cbdc8ac873c41f02d37949e7bd18a5ada417775947c6", kill_on_drop: false }` [INFO] [stderr] Checking belajar-rust v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unused variable: `logical` [INFO] [stdout] --> src/bin/09-primitive-type.rs:3:9 [INFO] [stdout] | [INFO] [stdout] 3 | let logical: bool = true; [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_logical` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `a_float` [INFO] [stdout] --> src/bin/09-primitive-type.rs:5:9 [INFO] [stdout] | [INFO] [stdout] 5 | let a_float: f64 = 1.0; // Regular annotation [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_a_float` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `an_integer` [INFO] [stdout] --> src/bin/09-primitive-type.rs:6:9 [INFO] [stdout] | [INFO] [stdout] 6 | let an_integer = 5i32; // Suffix annotation [INFO] [stdout] | ^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_an_integer` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `default_float` [INFO] [stdout] --> src/bin/09-primitive-type.rs:9:9 [INFO] [stdout] | [INFO] [stdout] 9 | let default_float = 3.0; // `f64` [INFO] [stdout] | ^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_default_float` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `default_integer` [INFO] [stdout] --> src/bin/09-primitive-type.rs:10:9 [INFO] [stdout] | [INFO] [stdout] 10 | let default_integer = 7; // `i32` [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_default_integer` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `inferred_type` is assigned to, but never used [INFO] [stdout] --> src/bin/09-primitive-type.rs:13:9 [INFO] [stdout] | [INFO] [stdout] 13 | let mut inferred_type = 12; // Type i64 is inferred from another line. [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: consider using `_inferred_type` instead [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `mutable` is assigned to, but never used [INFO] [stdout] --> src/bin/09-primitive-type.rs:17:9 [INFO] [stdout] | [INFO] [stdout] 17 | let mut mutable = 12; // Mutable `i32` [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: consider using `_mutable` instead [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `mutable` [INFO] [stdout] --> src/bin/09-primitive-type.rs:24:9 [INFO] [stdout] | [INFO] [stdout] 24 | let mutable = true; [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_mutable` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `my_array` [INFO] [stdout] --> src/bin/09-primitive-type.rs:29:9 [INFO] [stdout] | [INFO] [stdout] 29 | let my_array: [i32; 5] = [1, 2, 3, 4, 5]; [INFO] [stdout] | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_my_array` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `my_tuple` [INFO] [stdout] --> src/bin/09-primitive-type.rs:33:9 [INFO] [stdout] | [INFO] [stdout] 33 | let my_tuple = (5u32, 1u8, true, -5.04f32); [INFO] [stdout] | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_my_tuple` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `inferred_type` is never read [INFO] [stdout] --> src/bin/09-primitive-type.rs:14:5 [INFO] [stdout] | [INFO] [stdout] 14 | inferred_type = 4294967296i64; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] = note: `#[warn(unused_assignments)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `mutable` is never read [INFO] [stdout] --> src/bin/09-primitive-type.rs:18:5 [INFO] [stdout] | [INFO] [stdout] 18 | mutable = 21; [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `name` and `age` are never read [INFO] [stdout] --> src/bin/05-debug-pretty.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 2 | struct Person<'a> { [INFO] [stdout] | ------ fields in this struct [INFO] [stdout] 3 | name: &'a str, [INFO] [stdout] | ^^^^ [INFO] [stdout] 4 | age: u8 [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Person` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `name` and `age` are never read [INFO] [stdout] --> src/bin/05-debug-pretty.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 2 | struct Person<'a> { [INFO] [stdout] | ------ fields in this struct [INFO] [stdout] 3 | name: &'a str, [INFO] [stdout] | ^^^^ [INFO] [stdout] 4 | age: u8 [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Person` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `0`, `1`, `2`, and `3` are never read [INFO] [stdout] --> src/bin/11-tupples.rs:11:15 [INFO] [stdout] | [INFO] [stdout] 11 | struct Matrix(f32, f32, f32, f32); [INFO] [stdout] | ------ ^^^ ^^^ ^^^ ^^^ [INFO] [stdout] | | [INFO] [stdout] | fields in this struct [INFO] [stdout] | [INFO] [stdout] = help: consider removing these fields [INFO] [stdout] = note: `Matrix` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `red`, `green`, and `blue` are never read [INFO] [stdout] --> src/bin/08-print-struct.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 32 | struct Color { [INFO] [stdout] | ----- fields in this struct [INFO] [stdout] 33 | red: u8, [INFO] [stdout] | ^^^ [INFO] [stdout] 34 | green: u8, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 35 | blue: u8, [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Color` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: float has excessive precision [INFO] [stdout] --> src/bin/08-print-struct.rs:42:18 [INFO] [stdout] | [INFO] [stdout] 42 | lat: 53.347778, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#excessive_precision [INFO] [stdout] = note: `#[warn(clippy::excessive_precision)]` on by default [INFO] [stdout] help: consider changing the type or truncating it to [INFO] [stdout] | [INFO] [stdout] 42 - lat: 53.347778, [INFO] [stdout] 42 + lat: 53.347_78, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `0` is never read [INFO] [stdout] --> src/bin/04-debug-print.rs:4:18 [INFO] [stdout] | [INFO] [stdout] 4 | struct Structure(i32); [INFO] [stdout] | --------- ^^^ [INFO] [stdout] | | [INFO] [stdout] | field in this struct [INFO] [stdout] | [INFO] [stdout] = help: consider removing this field [INFO] [stdout] = note: `Structure` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `0` is never read [INFO] [stdout] --> src/bin/04-debug-print.rs:9:13 [INFO] [stdout] | [INFO] [stdout] 9 | struct Deep(Structure); [INFO] [stdout] | ---- ^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | field in this struct [INFO] [stdout] | [INFO] [stdout] = help: consider removing this field [INFO] [stdout] = note: `Deep` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `0`, `1`, `2`, and `3` are never read [INFO] [stdout] --> src/bin/11-tupples.rs:11:15 [INFO] [stdout] | [INFO] [stdout] 11 | struct Matrix(f32, f32, f32, f32); [INFO] [stdout] | ------ ^^^ ^^^ ^^^ ^^^ [INFO] [stdout] | | [INFO] [stdout] | fields in this struct [INFO] [stdout] | [INFO] [stdout] = help: consider removing these fields [INFO] [stdout] = note: `Matrix` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `logical` [INFO] [stdout] --> src/bin/09-primitive-type.rs:3:9 [INFO] [stdout] | [INFO] [stdout] 3 | let logical: bool = true; [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_logical` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `a_float` [INFO] [stdout] --> src/bin/09-primitive-type.rs:5:9 [INFO] [stdout] | [INFO] [stdout] 5 | let a_float: f64 = 1.0; // Regular annotation [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_a_float` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `an_integer` [INFO] [stdout] --> src/bin/09-primitive-type.rs:6:9 [INFO] [stdout] | [INFO] [stdout] 6 | let an_integer = 5i32; // Suffix annotation [INFO] [stdout] | ^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_an_integer` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `default_float` [INFO] [stdout] --> src/bin/09-primitive-type.rs:9:9 [INFO] [stdout] | [INFO] [stdout] 9 | let default_float = 3.0; // `f64` [INFO] [stdout] | ^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_default_float` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `default_integer` [INFO] [stdout] --> src/bin/09-primitive-type.rs:10:9 [INFO] [stdout] | [INFO] [stdout] 10 | let default_integer = 7; // `i32` [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_default_integer` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `inferred_type` is assigned to, but never used [INFO] [stdout] --> src/bin/09-primitive-type.rs:13:9 [INFO] [stdout] | [INFO] [stdout] 13 | let mut inferred_type = 12; // Type i64 is inferred from another line. [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: consider using `_inferred_type` instead [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `mutable` is assigned to, but never used [INFO] [stdout] --> src/bin/09-primitive-type.rs:17:9 [INFO] [stdout] | [INFO] [stdout] 17 | let mut mutable = 12; // Mutable `i32` [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: consider using `_mutable` instead [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `mutable` [INFO] [stdout] --> src/bin/09-primitive-type.rs:24:9 [INFO] [stdout] | [INFO] [stdout] 24 | let mutable = true; [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_mutable` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `my_array` [INFO] [stdout] --> src/bin/09-primitive-type.rs:29:9 [INFO] [stdout] | [INFO] [stdout] 29 | let my_array: [i32; 5] = [1, 2, 3, 4, 5]; [INFO] [stdout] | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_my_array` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `my_tuple` [INFO] [stdout] --> src/bin/09-primitive-type.rs:33:9 [INFO] [stdout] | [INFO] [stdout] 33 | let my_tuple = (5u32, 1u8, true, -5.04f32); [INFO] [stdout] | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_my_tuple` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `inferred_type` is never read [INFO] [stdout] --> src/bin/09-primitive-type.rs:14:5 [INFO] [stdout] | [INFO] [stdout] 14 | inferred_type = 4294967296i64; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] = note: `#[warn(unused_assignments)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `mutable` is never read [INFO] [stdout] --> src/bin/09-primitive-type.rs:18:5 [INFO] [stdout] | [INFO] [stdout] 18 | mutable = 21; [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded late initialization [INFO] [stdout] --> src/bin/24-variable-initialization.rs:16:5 [INFO] [stdout] | [INFO] [stdout] 16 | let another_binding; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ created here [INFO] [stdout] ... [INFO] [stdout] 22 | another_binding = 1; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ initialised here [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_late_init [INFO] [stdout] = note: `#[warn(clippy::needless_late_init)]` on by default [INFO] [stdout] help: move the declaration `another_binding` here [INFO] [stdout] | [INFO] [stdout] 16 ~ [INFO] [stdout] 17 | [INFO] [stdout] ... [INFO] [stdout] 21 | // Now we assign it [INFO] [stdout] 22 ~ let another_binding = 1; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: literal with an empty format string [INFO] [stdout] --> src/bin/03-formatted-print.rs:13:21 [INFO] [stdout] | [INFO] [stdout] 13 | object="the lazy dog", [INFO] [stdout] | _____________________^ [INFO] [stdout] 14 | | subject="the quick brown fox", [INFO] [stdout] 15 | | verb="jumps over"); [INFO] [stdout] | |______________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#print_literal [INFO] [stdout] = note: `#[warn(clippy::print_literal)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 12 - println!("{subject} {verb} {object}", [INFO] [stdout] 13 - object="the lazy dog", [INFO] [stdout] 14 - subject="the quick brown fox", [INFO] [stdout] 15 - verb="jumps over"); [INFO] [stdout] 12 + println!("the quick brown fox jumps over the lazy dog"); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: literal with an empty format string [INFO] [stdout] --> src/bin/03-formatted-print.rs:37:49 [INFO] [stdout] | [INFO] [stdout] 37 | println!("My name is {0}, {1} {0}", "Bond", "James"); [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#print_literal [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 37 - println!("My name is {0}, {1} {0}", "Bond", "James"); [INFO] [stdout] 37 + println!("My name is {0}, James {0}", "Bond"); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/bin/18-linked-list.rs:52:17 [INFO] [stdout] | [INFO] [stdout] 52 | format!("Nil") [INFO] [stdout] | ^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"Nil".to_string()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_format [INFO] [stdout] = note: `#[warn(clippy::useless_format)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/bin/18-linked-list.rs:52:17 [INFO] [stdout] | [INFO] [stdout] 52 | format!("Nil") [INFO] [stdout] | ^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"Nil".to_string()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_format [INFO] [stdout] = note: `#[warn(clippy::useless_format)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> src/bin/13-structs.rs:69:9 [INFO] [stdout] | [INFO] [stdout] 69 | bottom_right: bottom_right, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `bottom_right` [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: literal with an empty format string [INFO] [stdout] --> src/bin/03-formatted-print.rs:13:21 [INFO] [stdout] | [INFO] [stdout] 13 | object="the lazy dog", [INFO] [stdout] | _____________________^ [INFO] [stdout] 14 | | subject="the quick brown fox", [INFO] [stdout] 15 | | verb="jumps over"); [INFO] [stdout] | |______________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#print_literal [INFO] [stdout] = note: `#[warn(clippy::print_literal)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 12 - println!("{subject} {verb} {object}", [INFO] [stdout] 13 - object="the lazy dog", [INFO] [stdout] 14 - subject="the quick brown fox", [INFO] [stdout] 15 - verb="jumps over"); [INFO] [stdout] 12 + println!("the quick brown fox jumps over the lazy dog"); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: literal with an empty format string [INFO] [stdout] --> src/bin/03-formatted-print.rs:37:49 [INFO] [stdout] | [INFO] [stdout] 37 | println!("My name is {0}, {1} {0}", "Bond", "James"); [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#print_literal [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 37 - println!("My name is {0}, {1} {0}", "Bond", "James"); [INFO] [stdout] 37 + println!("My name is {0}, James {0}", "Bond"); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting integer literal to `u16` is unnecessary [INFO] [stdout] --> src/bin/26-casting.rs:32:38 [INFO] [stdout] | [INFO] [stdout] 32 | println!("1000 as a u16 is: {}", 1000 as u16); [INFO] [stdout] | ^^^^^^^^^^^ help: try: `1000_u16` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting integer literal to `u8` is unnecessary [INFO] [stdout] --> src/bin/26-casting.rs:36:38 [INFO] [stdout] | [INFO] [stdout] 36 | println!("1000 as a u8 is : {}", 1000 as u8); [INFO] [stdout] | ^^^^^^^^^^ help: try: `1000_u8` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting integer literal to `i16` is unnecessary [INFO] [stdout] --> src/bin/26-casting.rs:44:38 [INFO] [stdout] | [INFO] [stdout] 44 | println!(" 128 as a i16 is: {}", 128 as i16); [INFO] [stdout] | ^^^^^^^^^^ help: try: `128_i16` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting integer literal to `i8` is unnecessary [INFO] [stdout] --> src/bin/26-casting.rs:47:38 [INFO] [stdout] | [INFO] [stdout] 47 | println!(" 128 as a i8 is : {}", 128 as i8); [INFO] [stdout] | ^^^^^^^^^ help: try: `128_i8` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting integer literal to `u8` is unnecessary [INFO] [stdout] --> src/bin/26-casting.rs:50:38 [INFO] [stdout] | [INFO] [stdout] 50 | println!("1000 as a u8 is : {}", 1000 as u8); [INFO] [stdout] | ^^^^^^^^^^ help: try: `1000_u8` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting integer literal to `i8` is unnecessary [INFO] [stdout] --> src/bin/26-casting.rs:52:38 [INFO] [stdout] | [INFO] [stdout] 52 | println!(" 232 as a i8 is : {}", 232 as i8); [INFO] [stdout] | ^^^^^^^^^ help: try: `232_i8` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting a known NaN to u8 [INFO] [stdout] --> src/bin/26-casting.rs:57:38 [INFO] [stdout] | [INFO] [stdout] 57 | println!(" nan as u8 is : {}", f32::NAN as u8); [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: this always evaluates to 0 [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_nan_to_int [INFO] [stdout] = note: `#[warn(clippy::cast_nan_to_int)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/bin/10-literals-operator.rs:13:38 [INFO] [stdout] | [INFO] [stdout] 13 | println!("true AND false is {}", true && false); [INFO] [stdout] | ^^^^^^^^^^^^^ help: try: `false` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/bin/10-literals-operator.rs:14:37 [INFO] [stdout] | [INFO] [stdout] 14 | println!("true OR false is {}", true || false); [INFO] [stdout] | ^^^^^^^^^^^^^ help: try: `true` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/bin/10-literals-operator.rs:15:32 [INFO] [stdout] | [INFO] [stdout] 15 | println!("NOT true is {}", !true); [INFO] [stdout] | ^^^^^ help: try: `false` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `red`, `green`, and `blue` are never read [INFO] [stdout] --> src/bin/08-print-struct.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 32 | struct Color { [INFO] [stdout] | ----- fields in this struct [INFO] [stdout] 33 | red: u8, [INFO] [stdout] | ^^^ [INFO] [stdout] 34 | green: u8, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 35 | blue: u8, [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Color` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: float has excessive precision [INFO] [stdout] --> src/bin/08-print-struct.rs:42:18 [INFO] [stdout] | [INFO] [stdout] 42 | lat: 53.347778, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#excessive_precision [INFO] [stdout] = note: `#[warn(clippy::excessive_precision)]` on by default [INFO] [stdout] help: consider changing the type or truncating it to [INFO] [stdout] | [INFO] [stdout] 42 - lat: 53.347778, [INFO] [stdout] 42 + lat: 53.347_78, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant field names in struct initialization [INFO] [stdout] --> src/bin/13-structs.rs:69:9 [INFO] [stdout] | [INFO] [stdout] 69 | bottom_right: bottom_right, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `bottom_right` [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: casting integer literal to `u16` is unnecessary [INFO] [stdout] --> src/bin/26-casting.rs:32:38 [INFO] [stdout] | [INFO] [stdout] 32 | println!("1000 as a u16 is: {}", 1000 as u16); [INFO] [stdout] | ^^^^^^^^^^^ help: try: `1000_u16` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting integer literal to `u8` is unnecessary [INFO] [stdout] --> src/bin/26-casting.rs:36:38 [INFO] [stdout] | [INFO] [stdout] 36 | println!("1000 as a u8 is : {}", 1000 as u8); [INFO] [stdout] | ^^^^^^^^^^ help: try: `1000_u8` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting integer literal to `i16` is unnecessary [INFO] [stdout] --> src/bin/26-casting.rs:44:38 [INFO] [stdout] | [INFO] [stdout] 44 | println!(" 128 as a i16 is: {}", 128 as i16); [INFO] [stdout] | ^^^^^^^^^^ help: try: `128_i16` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting integer literal to `i8` is unnecessary [INFO] [stdout] --> src/bin/26-casting.rs:47:38 [INFO] [stdout] | [INFO] [stdout] 47 | println!(" 128 as a i8 is : {}", 128 as i8); [INFO] [stdout] | ^^^^^^^^^ help: try: `128_i8` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting integer literal to `u8` is unnecessary [INFO] [stdout] --> src/bin/26-casting.rs:50:38 [INFO] [stdout] | [INFO] [stdout] 50 | println!("1000 as a u8 is : {}", 1000 as u8); [INFO] [stdout] | ^^^^^^^^^^ help: try: `1000_u8` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting integer literal to `i8` is unnecessary [INFO] [stdout] --> src/bin/26-casting.rs:52:38 [INFO] [stdout] | [INFO] [stdout] 52 | println!(" 232 as a i8 is : {}", 232 as i8); [INFO] [stdout] | ^^^^^^^^^ help: try: `232_i8` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting a known NaN to u8 [INFO] [stdout] --> src/bin/26-casting.rs:57:38 [INFO] [stdout] | [INFO] [stdout] 57 | println!(" nan as u8 is : {}", f32::NAN as u8); [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: this always evaluates to 0 [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_nan_to_int [INFO] [stdout] = note: `#[warn(clippy::cast_nan_to_int)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/bin/10-literals-operator.rs:13:38 [INFO] [stdout] | [INFO] [stdout] 13 | println!("true AND false is {}", true && false); [INFO] [stdout] | ^^^^^^^^^^^^^ help: try: `false` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/bin/10-literals-operator.rs:14:37 [INFO] [stdout] | [INFO] [stdout] 14 | println!("true OR false is {}", true || false); [INFO] [stdout] | ^^^^^^^^^^^^^ help: try: `true` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/bin/10-literals-operator.rs:15:32 [INFO] [stdout] | [INFO] [stdout] 15 | println!("NOT true is {}", !true); [INFO] [stdout] | ^^^^^ help: try: `false` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded late initialization [INFO] [stdout] --> src/bin/24-variable-initialization.rs:16:5 [INFO] [stdout] | [INFO] [stdout] 16 | let another_binding; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ created here [INFO] [stdout] ... [INFO] [stdout] 22 | another_binding = 1; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ initialised here [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_late_init [INFO] [stdout] = note: `#[warn(clippy::needless_late_init)]` on by default [INFO] [stdout] help: move the declaration `another_binding` here [INFO] [stdout] | [INFO] [stdout] 16 ~ [INFO] [stdout] 17 | [INFO] [stdout] ... [INFO] [stdout] 21 | // Now we assign it [INFO] [stdout] 22 ~ let another_binding = 1; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `0` is never read [INFO] [stdout] --> src/bin/04-debug-print.rs:4:18 [INFO] [stdout] | [INFO] [stdout] 4 | struct Structure(i32); [INFO] [stdout] | --------- ^^^ [INFO] [stdout] | | [INFO] [stdout] | field in this struct [INFO] [stdout] | [INFO] [stdout] = help: consider removing this field [INFO] [stdout] = note: `Structure` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `0` is never read [INFO] [stdout] --> src/bin/04-debug-print.rs:9:13 [INFO] [stdout] | [INFO] [stdout] 9 | struct Deep(Structure); [INFO] [stdout] | ---- ^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | field in this struct [INFO] [stdout] | [INFO] [stdout] = help: consider removing this field [INFO] [stdout] = note: `Deep` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 1.35s [INFO] running `Command { std: "docker" "inspect" "9a13c0ec2826a63ed623cbdc8ac873c41f02d37949e7bd18a5ada417775947c6", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "9a13c0ec2826a63ed623cbdc8ac873c41f02d37949e7bd18a5ada417775947c6", kill_on_drop: false }` [INFO] [stdout] 9a13c0ec2826a63ed623cbdc8ac873c41f02d37949e7bd18a5ada417775947c6