[INFO] cloning repository https://github.com/flikeok/rust_example [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/flikeok/rust_example" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fflikeok%2Frust_example", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fflikeok%2Frust_example'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 5d7f73bbef7cd9c4ac23591a14b013d2337004a7 [INFO] building flikeok/rust_example against try#8b8eff55bd72abbb57167bc42222a7f91d41cb0d for pr-142134-abi-ast-error [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fflikeok%2Frust_example" "/workspace/builds/worker-1-tc2/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-1-tc2/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/flikeok/rust_example on toolchain 8b8eff55bd72abbb57167bc42222a7f91d41cb0d [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+8b8eff55bd72abbb57167bc42222a7f91d41cb0d" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/flikeok/rust_example [INFO] finished tweaking git repo https://github.com/flikeok/rust_example [INFO] tweaked toml for git repo https://github.com/flikeok/rust_example written to /workspace/builds/worker-1-tc2/source/Cargo.toml [INFO] crate git repo https://github.com/flikeok/rust_example 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" "+8b8eff55bd72abbb57167bc42222a7f91d41cb0d" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-tc2/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:eea15d5475069c3ef791f10c2c6b5af2ee421ef2da1e680ecce1cba46243983b" "/opt/rustwide/cargo-home/bin/cargo" "+8b8eff55bd72abbb57167bc42222a7f91d41cb0d" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 84dc2459b19c53db83b4721bcabdb288dae7710fe2dee0e2c06a5003a6125c72 [INFO] running `Command { std: "docker" "start" "-a" "84dc2459b19c53db83b4721bcabdb288dae7710fe2dee0e2c06a5003a6125c72", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "84dc2459b19c53db83b4721bcabdb288dae7710fe2dee0e2c06a5003a6125c72", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "84dc2459b19c53db83b4721bcabdb288dae7710fe2dee0e2c06a5003a6125c72", kill_on_drop: false }` [INFO] [stdout] 84dc2459b19c53db83b4721bcabdb288dae7710fe2dee0e2c06a5003a6125c72 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-tc2/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=warn" "-e" "RUSTDOCFLAGS=--cap-lints=warn" "-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:eea15d5475069c3ef791f10c2c6b5af2ee421ef2da1e680ecce1cba46243983b" "/opt/rustwide/cargo-home/bin/cargo" "+8b8eff55bd72abbb57167bc42222a7f91d41cb0d" "build" "--frozen" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] b9ee6be83f01ef6ece3cb74e8d54f2388291a72704519d11debe2ee12f779239 [INFO] running `Command { std: "docker" "start" "-a" "b9ee6be83f01ef6ece3cb74e8d54f2388291a72704519d11debe2ee12f779239", kill_on_drop: false }` [INFO] [stderr] Compiling rust_example v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unused imports: `CloseBox` and `OpenBox` [INFO] [stdout] --> src/ch10/structs.rs:1:16 [INFO] [stdout] | [INFO] [stdout] 1 | use self::my::{CloseBox, OpenBox}; [INFO] [stdout] | ^^^^^^^^ ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `my::hello` [INFO] [stdout] --> src/ch10/uses.rs:20:5 [INFO] [stdout] | [INFO] [stdout] 20 | use my::hello; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::str::FromStr` [INFO] [stdout] --> src/ch18/errors.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::str::FromStr; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `HashMap` and `HashSet` [INFO] [stdout] --> src/ch19/boxs.rs:1:24 [INFO] [stdout] | [INFO] [stdout] 1 | use std::collections::{HashMap, HashSet}; [INFO] [stdout] | ^^^^^^^ ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::rc::Rc` [INFO] [stdout] --> src/ch19/boxs.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use std::rc::Rc; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::sync::Arc` [INFO] [stdout] --> src/ch19/boxs.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use std::sync::Arc; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `JoinHandle` and `self` [INFO] [stdout] --> src/ch19/boxs.rs:4:19 [INFO] [stdout] | [INFO] [stdout] 4 | use std::thread::{self, JoinHandle}; [INFO] [stdout] | ^^^^ ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::process::Command` [INFO] [stdout] --> src/ch19/cmds.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::process::Command; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `File`, `Read`, `SeekFrom`, `Seek`, `Write`, `os::unix::fs::FileExt`, `path::Path`, `remove_file`, and `str::from_utf8` [INFO] [stdout] --> src/ch19/files.rs:2:10 [INFO] [stdout] | [INFO] [stdout] 2 | fs::{remove_file, File}, [INFO] [stdout] | ^^^^^^^^^^^ ^^^^ [INFO] [stdout] 3 | io::{Read, Seek, SeekFrom, Write}, [INFO] [stdout] | ^^^^ ^^^^ ^^^^^^^^ ^^^^^ [INFO] [stdout] 4 | os::unix::fs::FileExt, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] 5 | path::Path, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] 6 | str::from_utf8, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `ffi::OsStr`, `path::Path`, `sync::mpsc`, and `thread` [INFO] [stdout] --> src/ch19/threads.rs:1:11 [INFO] [stdout] | [INFO] [stdout] 1 | use std::{ffi::OsStr, path::Path, sync::mpsc, thread}; [INFO] [stdout] | ^^^^^^^^^^ ^^^^^^^^^^ ^^^^^^^^^^ ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fmt::format` [INFO] [stdout] --> src/ch6/to_strings.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::fmt::format; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:2:8 [INFO] [stdout] | [INFO] [stdout] 2 | fn hello() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `pub_hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:5:12 [INFO] [stdout] | [INFO] [stdout] 5 | pub fn pub_hello() { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `indirect_access` is never used [INFO] [stdout] --> src/ch10/mods.rs:9:12 [INFO] [stdout] | [INFO] [stdout] 9 | pub fn indirect_access() { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:15:12 [INFO] [stdout] | [INFO] [stdout] 15 | fn hello() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `pub_hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:18:46 [INFO] [stdout] | [INFO] [stdout] 18 | pub(in crate::ch10::mods::my_mod) fn pub_hello() { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `self_hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:22:22 [INFO] [stdout] | [INFO] [stdout] 22 | pub(self) fn self_hello() { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `super_hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:26:23 [INFO] [stdout] | [INFO] [stdout] 26 | pub(super) fn super_hello() { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `call_super_in_nested` is never used [INFO] [stdout] --> src/ch10/mods.rs:30:16 [INFO] [stdout] | [INFO] [stdout] 30 | pub fn call_super_in_nested() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `call_crate_hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:34:23 [INFO] [stdout] | [INFO] [stdout] 34 | pub(crate) fn call_crate_hello() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `OpenBox` is never constructed [INFO] [stdout] --> src/ch10/structs.rs:4:16 [INFO] [stdout] | [INFO] [stdout] 4 | pub struct OpenBox { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `CloseBox` is never constructed [INFO] [stdout] --> src/ch10/structs.rs:8:16 [INFO] [stdout] | [INFO] [stdout] 8 | pub struct CloseBox { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new` and `print` are never used [INFO] [stdout] --> src/ch10/structs.rs:16:16 [INFO] [stdout] | [INFO] [stdout] 12 | / impl CloseBox [INFO] [stdout] 13 | | where [INFO] [stdout] 14 | | T: std::fmt::Display, [INFO] [stdout] | |_____________________________- associated items in this implementation [INFO] [stdout] 15 | { [INFO] [stdout] 16 | pub fn new(t: T) -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 20 | pub fn print(&self) { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hello` is never used [INFO] [stdout] --> src/ch10/uses.rs:2:12 [INFO] [stdout] | [INFO] [stdout] 2 | pub fn hello() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `world` is never used [INFO] [stdout] --> src/ch10/uses.rs:5:12 [INFO] [stdout] | [INFO] [stdout] 5 | pub fn world() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hello` is never used [INFO] [stdout] --> src/ch10/uses.rs:10:16 [INFO] [stdout] | [INFO] [stdout] 10 | pub fn hello() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `call_hello` is never used [INFO] [stdout] --> src/ch10/uses.rs:13:16 [INFO] [stdout] | [INFO] [stdout] 13 | pub fn call_hello() { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `Animal` is never used [INFO] [stdout] --> src/ch16/traits.rs:1:7 [INFO] [stdout] | [INFO] [stdout] 1 | trait Animal { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Sheep` is never constructed [INFO] [stdout] --> src/ch16/traits.rs:5:8 [INFO] [stdout] | [INFO] [stdout] 5 | struct Sheep { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new_sheep` is never used [INFO] [stdout] --> src/ch16/traits.rs:10:12 [INFO] [stdout] | [INFO] [stdout] 9 | impl Sheep { [INFO] [stdout] | ---------- associated function in this implementation [INFO] [stdout] 10 | pub fn new_sheep() -> Self { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new_duck` is never used [INFO] [stdout] --> src/ch16/traits.rs:16:12 [INFO] [stdout] | [INFO] [stdout] 15 | impl Duck { [INFO] [stdout] | --------- associated function in this implementation [INFO] [stdout] 16 | pub fn new_duck() -> Self { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Duck` is never constructed [INFO] [stdout] --> src/ch16/traits.rs:27:8 [INFO] [stdout] | [INFO] [stdout] 27 | struct Duck { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `random_animal` is never used [INFO] [stdout] --> src/ch16/traits.rs:36:4 [INFO] [stdout] | [INFO] [stdout] 36 | fn random_animal(i: i32) -> Box { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `map_string` is never used [INFO] [stdout] --> src/ch18/maps.rs:1:4 [INFO] [stdout] | [INFO] [stdout] 1 | fn map_string(s: Option) -> Option { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: type alias `ParseIntResult` is never used [INFO] [stdout] --> src/ch18/results.rs:3:6 [INFO] [stdout] | [INFO] [stdout] 3 | type ParseIntResult = Result; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `two_plus` is never used [INFO] [stdout] --> src/ch18/results.rs:4:4 [INFO] [stdout] | [INFO] [stdout] 4 | fn two_plus(l: String, r: String) -> ParseIntResult { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `double_first` is never used [INFO] [stdout] --> src/ch18/results.rs:25:4 [INFO] [stdout] | [INFO] [stdout] 25 | fn double_first(vec: Vec<&str>) -> Option> { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Stu` is never constructed [INFO] [stdout] --> src/ch19/boxs.rs:7:8 [INFO] [stdout] | [INFO] [stdout] 7 | struct Stu<'a> { [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Stu` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new` is never used [INFO] [stdout] --> src/ch19/boxs.rs:13:12 [INFO] [stdout] | [INFO] [stdout] 12 | impl<'a> Stu<'a> { [INFO] [stdout] | ---------------- associated function in this implementation [INFO] [stdout] 13 | pub fn new(s: &'a str, i: i32) -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `a_plus_b` is never used [INFO] [stdout] --> src/ch19/boxs.rs:96:4 [INFO] [stdout] | [INFO] [stdout] 96 | fn a_plus_b(i: i32, j: i32) -> i32 { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `reverse` is never used [INFO] [stdout] --> src/ch2/tuple.rs:4:4 [INFO] [stdout] | [INFO] [stdout] 4 | fn reverse(left:i32,right:bool)->(bool,i32){ [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Matrix` is never constructed [INFO] [stdout] --> src/ch2/tuple.rs:24:8 [INFO] [stdout] | [INFO] [stdout] 24 | struct Matrix(f32, f32, f32, f32); [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Matrix` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `trans` is never used [INFO] [stdout] --> src/ch2/tuple.rs:36:8 [INFO] [stdout] | [INFO] [stdout] 33 | impl Matrix { [INFO] [stdout] | ----------- method in this implementation [INFO] [stdout] ... [INFO] [stdout] 36 | fn trans(&self)->Self{ [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `slice` is never used [INFO] [stdout] --> src/ch2/array.rs:12:4 [INFO] [stdout] | [INFO] [stdout] 12 | fn slice(s:&[i32]){ [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `0` and `1` are never read [INFO] [stdout] --> src/ch3/structs.rs:10:16 [INFO] [stdout] | [INFO] [stdout] 10 | pub struct Stu(i32,String); [INFO] [stdout] | --- ^^^ ^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | fields in this struct [INFO] [stdout] | [INFO] [stdout] = help: consider removing these fields [INFO] [stdout] = note: `Stu` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: static `MY_WORLD` is never used [INFO] [stdout] --> src/ch3/consts.rs:1:8 [INFO] [stdout] | [INFO] [stdout] 1 | static MY_WORLD:&'static str = "hello"; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `NUM` is never used [INFO] [stdout] --> src/ch3/consts.rs:2:7 [INFO] [stdout] | [INFO] [stdout] 2 | const NUM:i32 = 10; [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: type alias `MyInt` is never used [INFO] [stdout] --> src/ch5/types.rs:1:6 [INFO] [stdout] | [INFO] [stdout] 1 | type MyInt = i32; [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Color` is never used [INFO] [stdout] --> src/ch8/ifs.rs:42:6 [INFO] [stdout] | [INFO] [stdout] 42 | enum Color { [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] [INFO] [stdout] [INFO] [stdout] warning: fields `name` and `age` are never read [INFO] [stdout] --> src/ch8/ifs.rs:81:5 [INFO] [stdout] | [INFO] [stdout] 80 | pub struct Stu { [INFO] [stdout] | --- fields in this struct [INFO] [stdout] 81 | name: String, [INFO] [stdout] | ^^^^ [INFO] [stdout] 82 | age: i32, [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `apply` is never used [INFO] [stdout] --> src/ch9/closure.rs:140:4 [INFO] [stdout] | [INFO] [stdout] 140 | fn apply(f: F) [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.15s [INFO] running `Command { std: "docker" "inspect" "b9ee6be83f01ef6ece3cb74e8d54f2388291a72704519d11debe2ee12f779239", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "b9ee6be83f01ef6ece3cb74e8d54f2388291a72704519d11debe2ee12f779239", kill_on_drop: false }` [INFO] [stdout] b9ee6be83f01ef6ece3cb74e8d54f2388291a72704519d11debe2ee12f779239 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-tc2/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=warn" "-e" "RUSTDOCFLAGS=--cap-lints=warn" "-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:eea15d5475069c3ef791f10c2c6b5af2ee421ef2da1e680ecce1cba46243983b" "/opt/rustwide/cargo-home/bin/cargo" "+8b8eff55bd72abbb57167bc42222a7f91d41cb0d" "test" "--frozen" "--no-run" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] ff663b5ff0472bacb45059dafd02f5679678031ef83305ccb2d0381e8c6e2106 [INFO] running `Command { std: "docker" "start" "-a" "ff663b5ff0472bacb45059dafd02f5679678031ef83305ccb2d0381e8c6e2106", kill_on_drop: false }` [INFO] [stdout] warning: unused imports: `CloseBox` and `OpenBox` [INFO] [stdout] --> src/ch10/structs.rs:1:16 [INFO] [stdout] | [INFO] [stdout] 1 | use self::my::{CloseBox, OpenBox}; [INFO] [stdout] | ^^^^^^^^ ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `my::hello` [INFO] [stdout] --> src/ch10/uses.rs:20:5 [INFO] [stdout] | [INFO] [stdout] 20 | use my::hello; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::str::FromStr` [INFO] [stdout] --> src/ch18/errors.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::str::FromStr; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `HashMap` and `HashSet` [INFO] [stdout] --> src/ch19/boxs.rs:1:24 [INFO] [stdout] | [INFO] [stdout] 1 | use std::collections::{HashMap, HashSet}; [INFO] [stdout] | ^^^^^^^ ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::rc::Rc` [INFO] [stdout] --> src/ch19/boxs.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use std::rc::Rc; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::sync::Arc` [INFO] [stdout] --> src/ch19/boxs.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use std::sync::Arc; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `JoinHandle` and `self` [INFO] [stdout] --> src/ch19/boxs.rs:4:19 [INFO] [stdout] | [INFO] [stdout] 4 | use std::thread::{self, JoinHandle}; [INFO] [stdout] | ^^^^ ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::process::Command` [INFO] [stdout] --> src/ch19/cmds.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::process::Command; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `File`, `Read`, `SeekFrom`, `Seek`, `Write`, `os::unix::fs::FileExt`, `path::Path`, `remove_file`, and `str::from_utf8` [INFO] [stdout] --> src/ch19/files.rs:2:10 [INFO] [stdout] | [INFO] [stdout] 2 | fs::{remove_file, File}, [INFO] [stdout] | ^^^^^^^^^^^ ^^^^ [INFO] [stdout] 3 | io::{Read, Seek, SeekFrom, Write}, [INFO] [stdout] | ^^^^ ^^^^ ^^^^^^^^ ^^^^^ [INFO] [stdout] 4 | os::unix::fs::FileExt, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] 5 | path::Path, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] 6 | str::from_utf8, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `ffi::OsStr`, `path::Path`, `sync::mpsc`, and `thread` [INFO] [stdout] --> src/ch19/threads.rs:1:11 [INFO] [stdout] | [INFO] [stdout] 1 | use std::{ffi::OsStr, path::Path, sync::mpsc, thread}; [INFO] [stdout] | ^^^^^^^^^^ ^^^^^^^^^^ ^^^^^^^^^^ ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fmt::format` [INFO] [stdout] --> src/ch6/to_strings.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::fmt::format; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:2:8 [INFO] [stdout] | [INFO] [stdout] 2 | fn hello() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `pub_hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:5:12 [INFO] [stdout] | [INFO] [stdout] 5 | pub fn pub_hello() { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `indirect_access` is never used [INFO] [stdout] --> src/ch10/mods.rs:9:12 [INFO] [stdout] | [INFO] [stdout] 9 | pub fn indirect_access() { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:15:12 [INFO] [stdout] | [INFO] [stdout] 15 | fn hello() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `pub_hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:18:46 [INFO] [stdout] | [INFO] [stdout] 18 | pub(in crate::ch10::mods::my_mod) fn pub_hello() { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `self_hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:22:22 [INFO] [stdout] | [INFO] [stdout] 22 | pub(self) fn self_hello() { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `super_hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:26:23 [INFO] [stdout] | [INFO] [stdout] 26 | pub(super) fn super_hello() { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `call_super_in_nested` is never used [INFO] [stdout] --> src/ch10/mods.rs:30:16 [INFO] [stdout] | [INFO] [stdout] 30 | pub fn call_super_in_nested() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `call_crate_hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:34:23 [INFO] [stdout] | [INFO] [stdout] 34 | pub(crate) fn call_crate_hello() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `OpenBox` is never constructed [INFO] [stdout] --> src/ch10/structs.rs:4:16 [INFO] [stdout] | [INFO] [stdout] 4 | pub struct OpenBox { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `CloseBox` is never constructed [INFO] [stdout] --> src/ch10/structs.rs:8:16 [INFO] [stdout] | [INFO] [stdout] 8 | pub struct CloseBox { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new` and `print` are never used [INFO] [stdout] --> src/ch10/structs.rs:16:16 [INFO] [stdout] | [INFO] [stdout] 12 | / impl CloseBox [INFO] [stdout] 13 | | where [INFO] [stdout] 14 | | T: std::fmt::Display, [INFO] [stdout] | |_____________________________- associated items in this implementation [INFO] [stdout] 15 | { [INFO] [stdout] 16 | pub fn new(t: T) -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 20 | pub fn print(&self) { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hello` is never used [INFO] [stdout] --> src/ch10/uses.rs:2:12 [INFO] [stdout] | [INFO] [stdout] 2 | pub fn hello() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `world` is never used [INFO] [stdout] --> src/ch10/uses.rs:5:12 [INFO] [stdout] | [INFO] [stdout] 5 | pub fn world() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hello` is never used [INFO] [stdout] --> src/ch10/uses.rs:10:16 [INFO] [stdout] | [INFO] [stdout] 10 | pub fn hello() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `call_hello` is never used [INFO] [stdout] --> src/ch10/uses.rs:13:16 [INFO] [stdout] | [INFO] [stdout] 13 | pub fn call_hello() { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `Animal` is never used [INFO] [stdout] --> src/ch16/traits.rs:1:7 [INFO] [stdout] | [INFO] [stdout] 1 | trait Animal { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Sheep` is never constructed [INFO] [stdout] --> src/ch16/traits.rs:5:8 [INFO] [stdout] | [INFO] [stdout] 5 | struct Sheep { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new_sheep` is never used [INFO] [stdout] --> src/ch16/traits.rs:10:12 [INFO] [stdout] | [INFO] [stdout] 9 | impl Sheep { [INFO] [stdout] | ---------- associated function in this implementation [INFO] [stdout] 10 | pub fn new_sheep() -> Self { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new_duck` is never used [INFO] [stdout] --> src/ch16/traits.rs:16:12 [INFO] [stdout] | [INFO] [stdout] 15 | impl Duck { [INFO] [stdout] | --------- associated function in this implementation [INFO] [stdout] 16 | pub fn new_duck() -> Self { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Duck` is never constructed [INFO] [stdout] --> src/ch16/traits.rs:27:8 [INFO] [stdout] | [INFO] [stdout] 27 | struct Duck { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `random_animal` is never used [INFO] [stdout] --> src/ch16/traits.rs:36:4 [INFO] [stdout] | [INFO] [stdout] 36 | fn random_animal(i: i32) -> Box { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `map_string` is never used [INFO] [stdout] --> src/ch18/maps.rs:1:4 [INFO] [stdout] | [INFO] [stdout] 1 | fn map_string(s: Option) -> Option { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: type alias `ParseIntResult` is never used [INFO] [stdout] --> src/ch18/results.rs:3:6 [INFO] [stdout] | [INFO] [stdout] 3 | type ParseIntResult = Result; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `two_plus` is never used [INFO] [stdout] --> src/ch18/results.rs:4:4 [INFO] [stdout] | [INFO] [stdout] 4 | fn two_plus(l: String, r: String) -> ParseIntResult { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `double_first` is never used [INFO] [stdout] --> src/ch18/results.rs:25:4 [INFO] [stdout] | [INFO] [stdout] 25 | fn double_first(vec: Vec<&str>) -> Option> { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Stu` is never constructed [INFO] [stdout] --> src/ch19/boxs.rs:7:8 [INFO] [stdout] | [INFO] [stdout] 7 | struct Stu<'a> { [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Stu` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new` is never used [INFO] [stdout] --> src/ch19/boxs.rs:13:12 [INFO] [stdout] | [INFO] [stdout] 12 | impl<'a> Stu<'a> { [INFO] [stdout] | ---------------- associated function in this implementation [INFO] [stdout] 13 | pub fn new(s: &'a str, i: i32) -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `a_plus_b` is never used [INFO] [stdout] --> src/ch19/boxs.rs:96:4 [INFO] [stdout] | [INFO] [stdout] 96 | fn a_plus_b(i: i32, j: i32) -> i32 { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `reverse` is never used [INFO] [stdout] --> src/ch2/tuple.rs:4:4 [INFO] [stdout] | [INFO] [stdout] 4 | fn reverse(left:i32,right:bool)->(bool,i32){ [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Matrix` is never constructed [INFO] [stdout] --> src/ch2/tuple.rs:24:8 [INFO] [stdout] | [INFO] [stdout] 24 | struct Matrix(f32, f32, f32, f32); [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Matrix` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `trans` is never used [INFO] [stdout] --> src/ch2/tuple.rs:36:8 [INFO] [stdout] | [INFO] [stdout] 33 | impl Matrix { [INFO] [stdout] | ----------- method in this implementation [INFO] [stdout] ... [INFO] [stdout] 36 | fn trans(&self)->Self{ [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `slice` is never used [INFO] [stdout] --> src/ch2/array.rs:12:4 [INFO] [stdout] | [INFO] [stdout] 12 | fn slice(s:&[i32]){ [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `0` and `1` are never read [INFO] [stdout] --> src/ch3/structs.rs:10:16 [INFO] [stdout] | [INFO] [stdout] 10 | pub struct Stu(i32,String); [INFO] [stdout] | --- ^^^ ^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | fields in this struct [INFO] [stdout] | [INFO] [stdout] = help: consider removing these fields [INFO] [stdout] = note: `Stu` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: static `MY_WORLD` is never used [INFO] [stdout] --> src/ch3/consts.rs:1:8 [INFO] [stdout] | [INFO] [stdout] 1 | static MY_WORLD:&'static str = "hello"; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `NUM` is never used [INFO] [stdout] --> src/ch3/consts.rs:2:7 [INFO] [stdout] | [INFO] [stdout] 2 | const NUM:i32 = 10; [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: type alias `MyInt` is never used [INFO] [stdout] --> src/ch5/types.rs:1:6 [INFO] [stdout] | [INFO] [stdout] 1 | type MyInt = i32; [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Color` is never used [INFO] [stdout] --> src/ch8/ifs.rs:42:6 [INFO] [stdout] | [INFO] [stdout] 42 | enum Color { [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] [INFO] [stdout] [INFO] [stdout] warning: fields `name` and `age` are never read [INFO] [stdout] --> src/ch8/ifs.rs:81:5 [INFO] [stdout] | [INFO] [stdout] 80 | pub struct Stu { [INFO] [stdout] | --- fields in this struct [INFO] [stdout] 81 | name: String, [INFO] [stdout] | ^^^^ [INFO] [stdout] 82 | age: i32, [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `apply` is never used [INFO] [stdout] --> src/ch9/closure.rs:140:4 [INFO] [stdout] | [INFO] [stdout] 140 | fn apply(f: F) [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Compiling rust_example v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unused import: `std::str::FromStr` [INFO] [stdout] --> src/ch18/errors.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::str::FromStr; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `JoinHandle` [INFO] [stdout] --> src/ch19/boxs.rs:4:25 [INFO] [stdout] | [INFO] [stdout] 4 | use std::thread::{self, JoinHandle}; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `os::unix::fs::FileExt` and `str::from_utf8` [INFO] [stdout] --> src/ch19/files.rs:4:5 [INFO] [stdout] | [INFO] [stdout] 4 | os::unix::fs::FileExt, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] 5 | path::Path, [INFO] [stdout] 6 | str::from_utf8, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fmt::format` [INFO] [stdout] --> src/ch6/to_strings.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::fmt::format; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `j` [INFO] [stdout] --> src/ch19/threads.rs:14:9 [INFO] [stdout] | [INFO] [stdout] 14 | for j in 0..10 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_j` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `inferred_type` is never read [INFO] [stdout] --> src/ch2/num_type.rs:5:13 [INFO] [stdout] | [INFO] [stdout] 5 | let mut inferred_type = 12; // 根据下一行的赋值推断为 i64 类型 [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] = note: `#[warn(unused_assignments)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `mut_able` is never read [INFO] [stdout] --> src/ch2/num_type.rs:9:13 [INFO] [stdout] | [INFO] [stdout] 9 | let mut mut_able = 12; // Mutable `i32` [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unreachable pattern [INFO] [stdout] --> src/ch8/ifs.rs:75:9 [INFO] [stdout] | [INFO] [stdout] 71 | value => { [INFO] [stdout] | ----- matches any value [INFO] [stdout] ... [INFO] [stdout] 75 | _ => 0, [INFO] [stdout] | ^ no value can reach this [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unreachable_patterns)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:2:8 [INFO] [stdout] | [INFO] [stdout] 2 | fn hello() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `indirect_access` is never used [INFO] [stdout] --> src/ch10/mods.rs:9:12 [INFO] [stdout] | [INFO] [stdout] 9 | pub fn indirect_access() { [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:15:12 [INFO] [stdout] | [INFO] [stdout] 15 | fn hello() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `pub_hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:18:46 [INFO] [stdout] | [INFO] [stdout] 18 | pub(in crate::ch10::mods::my_mod) fn pub_hello() { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `self_hello` is never used [INFO] [stdout] --> src/ch10/mods.rs:22:22 [INFO] [stdout] | [INFO] [stdout] 22 | pub(self) fn self_hello() { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hello` is never used [INFO] [stdout] --> src/ch10/uses.rs:10:16 [INFO] [stdout] | [INFO] [stdout] 10 | pub fn hello() { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `call_hello` is never used [INFO] [stdout] --> src/ch10/uses.rs:13:16 [INFO] [stdout] | [INFO] [stdout] 13 | pub fn call_hello() { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `name` is never read [INFO] [stdout] --> src/ch16/traits.rs:6:5 [INFO] [stdout] | [INFO] [stdout] 5 | struct Sheep { [INFO] [stdout] | ----- field in this struct [INFO] [stdout] 6 | name: &'static str, [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `name` is never read [INFO] [stdout] --> src/ch16/traits.rs:28:5 [INFO] [stdout] | [INFO] [stdout] 27 | struct Duck { [INFO] [stdout] | ---- field in this struct [INFO] [stdout] 28 | name: &'static str, [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Color` is never used [INFO] [stdout] --> src/ch8/ifs.rs:42:6 [INFO] [stdout] | [INFO] [stdout] 42 | enum Color { [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] [INFO] [stdout] [INFO] [stdout] warning: field `age` is never read [INFO] [stdout] --> src/ch8/ifs.rs:82:5 [INFO] [stdout] | [INFO] [stdout] 80 | pub struct Stu { [INFO] [stdout] | --- field in this struct [INFO] [stdout] 81 | name: String, [INFO] [stdout] 82 | age: i32, [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `test` profile [unoptimized + debuginfo] target(s) in 1.33s [INFO] running `Command { std: "docker" "inspect" "ff663b5ff0472bacb45059dafd02f5679678031ef83305ccb2d0381e8c6e2106", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "ff663b5ff0472bacb45059dafd02f5679678031ef83305ccb2d0381e8c6e2106", kill_on_drop: false }` [INFO] [stdout] ff663b5ff0472bacb45059dafd02f5679678031ef83305ccb2d0381e8c6e2106