[INFO] cloning repository https://github.com/Xiao-VoV/rust_algorithms [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/Xiao-VoV/rust_algorithms" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FXiao-VoV%2Frust_algorithms", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FXiao-VoV%2Frust_algorithms'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 781d0bcc152570269243f1a24b763e83d51e5987 [INFO] checking Xiao-VoV/rust_algorithms/781d0bcc152570269243f1a24b763e83d51e5987 against master#ab869e094a907cc5d19b4080f22eccaf347f1f95 for pr-129604 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FXiao-VoV%2Frust_algorithms" "/workspace/builds/worker-0-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-0-tc1/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/Xiao-VoV/rust_algorithms on toolchain ab869e094a907cc5d19b4080f22eccaf347f1f95 [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+ab869e094a907cc5d19b4080f22eccaf347f1f95" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/Xiao-VoV/rust_algorithms [INFO] finished tweaking git repo https://github.com/Xiao-VoV/rust_algorithms [INFO] tweaked toml for git repo https://github.com/Xiao-VoV/rust_algorithms written to /workspace/builds/worker-0-tc1/source/Cargo.toml [INFO] crate git repo https://github.com/Xiao-VoV/rust_algorithms 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" "+ab869e094a907cc5d19b4080f22eccaf347f1f95" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-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:923055f121b5182466d55868a8b05e67af8ba4a3a3f6bad814e953ca3cd3ac2a" "/opt/rustwide/cargo-home/bin/cargo" "+ab869e094a907cc5d19b4080f22eccaf347f1f95" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] e901f5f2cfb5df39a73fc87cd817453ba52c1fc12b377746852c1fcbc252cce8 [INFO] running `Command { std: "docker" "start" "-a" "e901f5f2cfb5df39a73fc87cd817453ba52c1fc12b377746852c1fcbc252cce8", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "e901f5f2cfb5df39a73fc87cd817453ba52c1fc12b377746852c1fcbc252cce8", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "e901f5f2cfb5df39a73fc87cd817453ba52c1fc12b377746852c1fcbc252cce8", kill_on_drop: false }` [INFO] [stdout] e901f5f2cfb5df39a73fc87cd817453ba52c1fc12b377746852c1fcbc252cce8 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-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:923055f121b5182466d55868a8b05e67af8ba4a3a3f6bad814e953ca3cd3ac2a" "/opt/rustwide/cargo-home/bin/cargo" "+ab869e094a907cc5d19b4080f22eccaf347f1f95" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 37fc0529e0c85c32f8e9b146c6ad015c786c7997fc63d013bb1a5767d0d75a87 [INFO] running `Command { std: "docker" "start" "-a" "37fc0529e0c85c32f8e9b146c6ad015c786c7997fc63d013bb1a5767d0d75a87", kill_on_drop: false }` [INFO] [stderr] Compiling proc-macro2 v1.0.85 [INFO] [stderr] Compiling autocfg v1.3.0 [INFO] [stderr] Checking futures-core v0.3.30 [INFO] [stderr] Checking futures-sink v0.3.30 [INFO] [stderr] Checking futures-task v0.3.30 [INFO] [stderr] Checking memchr v2.7.4 [INFO] [stderr] Checking futures-io v0.3.30 [INFO] [stderr] Checking futures-channel v0.3.30 [INFO] [stderr] Compiling slab v0.4.9 [INFO] [stderr] Compiling quote v1.0.36 [INFO] [stderr] Compiling syn v2.0.66 [INFO] [stderr] Compiling futures-macro v0.3.30 [INFO] [stderr] Checking futures-util v0.3.30 [INFO] [stderr] Checking futures-executor v0.3.30 [INFO] [stderr] Checking futures v0.3.30 [INFO] [stderr] Checking rust_algorithm v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unused import: `Arc` [INFO] [stdout] --> src/design_patterns/singleton_pattern/mod.rs:14:21 [INFO] [stdout] | [INFO] [stdout] 14 | use std::sync::{Arc, RwLock}; [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `super::*` [INFO] [stdout] --> src/search/linear_search.rs:11:9 [INFO] [stdout] | [INFO] [stdout] 11 | use super::*; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `iter::Rev` and `mem::swap` [INFO] [stdout] --> src/sorting/heap_sort.rs:1:11 [INFO] [stdout] | [INFO] [stdout] 1 | use std::{iter::Rev, mem::swap}; [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fmt::Display` [INFO] [stdout] --> src/sorting/insert_sort.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::fmt::Display; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::ops::DerefMut` [INFO] [stdout] --> src/sorting/merge_sort.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::ops::DerefMut; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `mem::swap` and `ops::Deref` [INFO] [stdout] --> src/sorting/select_sort.rs:1:11 [INFO] [stdout] | [INFO] [stdout] 1 | use std::{mem::swap, ops::Deref}; [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `error` [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | error, [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variant `male` should have an upper camel case name [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:8:5 [INFO] [stdout] | [INFO] [stdout] 8 | male, [INFO] [stdout] | ^^^^ help: convert the identifier to upper camel case: `Male` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_camel_case_types)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variant `female` should have an upper camel case name [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:9:5 [INFO] [stdout] | [INFO] [stdout] 9 | female, [INFO] [stdout] | ^^^^^^ help: convert the identifier to upper camel case (notice the capitalization): `Female` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variant `other` should have an upper camel case name [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:10:5 [INFO] [stdout] | [INFO] [stdout] 10 | other, [INFO] [stdout] | ^^^^^ help: convert the identifier to upper camel case (notice the capitalization): `Other` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `RecvError` [INFO] [stdout] --> src/thread/thread_message.rs:2:24 [INFO] [stdout] | [INFO] [stdout] 2 | sync::mpsc::{self, RecvError}, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `sleep` [INFO] [stdout] --> src/thread/mod.rs:5:20 [INFO] [stdout] | [INFO] [stdout] 5 | thread::{self, sleep}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `borrow::Borrow` [INFO] [stdout] --> src/datastruct/list.rs:1:11 [INFO] [stdout] | [INFO] [stdout] 1 | use std::{borrow::Borrow, cell::RefCell, rc::Rc}; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Arc` [INFO] [stdout] --> src/design_patterns/singleton_pattern/mod.rs:14:21 [INFO] [stdout] | [INFO] [stdout] 14 | use std::sync::{Arc, RwLock}; [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `super::*` [INFO] [stdout] --> src/design_patterns/singleton_pattern/mod.rs:55:9 [INFO] [stdout] | [INFO] [stdout] 55 | use super::*; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `iter::Rev` and `mem::swap` [INFO] [stdout] --> src/sorting/heap_sort.rs:1:11 [INFO] [stdout] | [INFO] [stdout] 1 | use std::{iter::Rev, mem::swap}; [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::fmt::Display` [INFO] [stdout] --> src/sorting/insert_sort.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::fmt::Display; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::ops::DerefMut` [INFO] [stdout] --> src/sorting/merge_sort.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::ops::DerefMut; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `mem::swap` and `ops::Deref` [INFO] [stdout] --> src/sorting/select_sort.rs:1:11 [INFO] [stdout] | [INFO] [stdout] 1 | use std::{mem::swap, ops::Deref}; [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `error` [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | error, [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variant `male` should have an upper camel case name [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:8:5 [INFO] [stdout] | [INFO] [stdout] 8 | male, [INFO] [stdout] | ^^^^ help: convert the identifier to upper camel case: `Male` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_camel_case_types)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variant `female` should have an upper camel case name [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:9:5 [INFO] [stdout] | [INFO] [stdout] 9 | female, [INFO] [stdout] | ^^^^^^ help: convert the identifier to upper camel case (notice the capitalization): `Female` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variant `other` should have an upper camel case name [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:10:5 [INFO] [stdout] | [INFO] [stdout] 10 | other, [INFO] [stdout] | ^^^^^ help: convert the identifier to upper camel case (notice the capitalization): `Other` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `RecvError` [INFO] [stdout] --> src/thread/thread_message.rs:2:24 [INFO] [stdout] | [INFO] [stdout] 2 | sync::mpsc::{self, RecvError}, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `sleep` [INFO] [stdout] --> src/thread/mod.rs:5:20 [INFO] [stdout] | [INFO] [stdout] 5 | thread::{self, sleep}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `super::*` [INFO] [stdout] --> src/lib.rs:11:9 [INFO] [stdout] | [INFO] [stdout] 11 | use super::*; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `do_something` is never used [INFO] [stdout] --> src/async_test/mod.rs:1:10 [INFO] [stdout] | [INFO] [stdout] 1 | async fn do_something() { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `test_async` is never used [INFO] [stdout] --> src/async_test/mod.rs:9:4 [INFO] [stdout] | [INFO] [stdout] 9 | fn test_async() { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new` is never used [INFO] [stdout] --> src/async_test/timer_future.rs:61:12 [INFO] [stdout] | [INFO] [stdout] 58 | impl TimerFuture { [INFO] [stdout] | ---------------- associated function in this implementation [INFO] [stdout] ... [INFO] [stdout] 61 | pub fn new(duration: Duration) -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Executor` is never constructed [INFO] [stdout] --> src/async_test/timer_future.rs:85:8 [INFO] [stdout] | [INFO] [stdout] 85 | struct Executor { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Spawner` is never constructed [INFO] [stdout] --> src/async_test/timer_future.rs:91:8 [INFO] [stdout] | [INFO] [stdout] 91 | struct Spawner { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `future` is never read [INFO] [stdout] --> src/async_test/timer_future.rs:104:5 [INFO] [stdout] | [INFO] [stdout] 96 | struct Task { [INFO] [stdout] | ---- field in this struct [INFO] [stdout] ... [INFO] [stdout] 104 | future: Mutex>>, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `new_executor_and_spawner` is never used [INFO] [stdout] --> src/async_test/timer_future.rs:110:4 [INFO] [stdout] | [INFO] [stdout] 110 | fn new_executor_and_spawner() -> (Executor, Spawner) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `spawn` is never used [INFO] [stdout] --> src/async_test/timer_future.rs:120:8 [INFO] [stdout] | [INFO] [stdout] 119 | impl Spawner { [INFO] [stdout] | ------------ method in this implementation [INFO] [stdout] 120 | fn spawn(&self, future: impl Future + 'static + Send) { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `run` is never used [INFO] [stdout] --> src/async_test/timer_future.rs:143:8 [INFO] [stdout] | [INFO] [stdout] 142 | impl Executor { [INFO] [stdout] | ------------- method in this implementation [INFO] [stdout] 143 | fn run(&self) { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `next` is never read [INFO] [stdout] --> src/datastruct/list.rs:6:5 [INFO] [stdout] | [INFO] [stdout] 3 | pub struct LinkedList { [INFO] [stdout] | ---------- field in this struct [INFO] [stdout] ... [INFO] [stdout] 6 | next: RefCell>>, [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] note: the lint level is defined here [INFO] [stdout] --> src/lib.rs:2:8 [INFO] [stdout] | [INFO] [stdout] 2 | #[warn(dead_code)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new`, `push_back`, `push_back_by_value`, and `print_list` are never used [INFO] [stdout] --> src/datastruct/list.rs:18:12 [INFO] [stdout] | [INFO] [stdout] 17 | impl LinkedList { [INFO] [stdout] | --------------- associated items in this implementation [INFO] [stdout] 18 | pub fn new(value: i32) -> Rc { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 25 | pub fn push_back(&self, node: Rc) { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 33 | pub fn push_back_by_value(&mut self, value: i32) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 37 | pub fn print_list(&self) { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variants `Female` and `Other` are never constructed [INFO] [stdout] --> src/design_patterns/singleton_pattern/mod.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 1 | enum Gender { [INFO] [stdout] | ------ variants in this enum [INFO] [stdout] 2 | Male, [INFO] [stdout] 3 | Female, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] 4 | Other, [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `name`, `age`, and `gender` are never read [INFO] [stdout] --> src/design_patterns/singleton_pattern/mod.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 6 | struct Single { [INFO] [stdout] | ------ fields in this struct [INFO] [stdout] 7 | name: String, [INFO] [stdout] | ^^^^ [INFO] [stdout] 8 | age: usize, [INFO] [stdout] | ^^^ [INFO] [stdout] 9 | gender: Gender, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: static `GLOBAL_SINGLE` is never used [INFO] [stdout] --> src/design_patterns/singleton_pattern/mod.rs:15:12 [INFO] [stdout] | [INFO] [stdout] 15 | static GLOBAL_SINGLE: Lazy> = Lazy::new(|| { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `draw` is never used [INFO] [stdout] --> src/object_oriented/trait_object.rs:2:8 [INFO] [stdout] | [INFO] [stdout] 1 | pub trait Draw { [INFO] [stdout] | ---- method in this trait [INFO] [stdout] 2 | fn draw(&self); [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Screen` is never constructed [INFO] [stdout] --> src/object_oriented/trait_object.rs:5:12 [INFO] [stdout] | [INFO] [stdout] 5 | pub struct Screen { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `run` is never used [INFO] [stdout] --> src/object_oriented/trait_object.rs:10:12 [INFO] [stdout] | [INFO] [stdout] 9 | impl Screen { [INFO] [stdout] | ----------- method in this implementation [INFO] [stdout] 10 | pub fn run(&self) { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `width` and `height` are never read [INFO] [stdout] --> src/object_oriented/trait_object.rs:18:9 [INFO] [stdout] | [INFO] [stdout] 17 | pub struct Button { [INFO] [stdout] | ------ fields in this struct [INFO] [stdout] 18 | pub width: u32, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 19 | pub height: u32, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `width` and `height` are never read [INFO] [stdout] --> src/object_oriented/trait_object.rs:29:5 [INFO] [stdout] | [INFO] [stdout] 28 | pub struct SelectBox { [INFO] [stdout] | --------- fields in this struct [INFO] [stdout] 29 | width: u32, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 30 | height: u32, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `binary_search` is never used [INFO] [stdout] --> src/search/binary_search.rs:1:8 [INFO] [stdout] | [INFO] [stdout] 1 | pub fn binary_search(vec: &mut [T], target: &T) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bineary_search` is never used [INFO] [stdout] --> src/search/binary_search.rs:18:8 [INFO] [stdout] | [INFO] [stdout] 18 | pub fn bineary_search(vec: &Vec, target: i64) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bineary_search_01` is never used [INFO] [stdout] --> src/search/binary_search.rs:38:8 [INFO] [stdout] | [INFO] [stdout] 38 | pub fn bineary_search_01(vec: &Vec, target: i64) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bineary_search_02` is never used [INFO] [stdout] --> src/search/binary_search.rs:60:8 [INFO] [stdout] | [INFO] [stdout] 60 | pub fn bineary_search_02(vec: &Vec, target: i64) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `linear_search` is never used [INFO] [stdout] --> src/search/linear_search.rs:1:8 [INFO] [stdout] | [INFO] [stdout] 1 | pub fn linear_search(value: &T, arr: &[T]) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bubble_sort` is never used [INFO] [stdout] --> src/sorting/bubble_sort.rs:1:8 [INFO] [stdout] | [INFO] [stdout] 1 | pub fn bubble_sort(mut vec: Vec) -> Vec [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `heap_sort_start_at_1` is never used [INFO] [stdout] --> src/sorting/heap_sort.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | pub fn heap_sort_start_at_1(vec: &mut [T]) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `build_heap` is never used [INFO] [stdout] --> src/sorting/heap_sort.rs:12:4 [INFO] [stdout] | [INFO] [stdout] 12 | fn build_heap(vec: &mut [T]) { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `heapify` is never used [INFO] [stdout] --> src/sorting/heap_sort.rs:19:4 [INFO] [stdout] | [INFO] [stdout] 19 | fn heapify(vec: &mut [T], i: usize, max_index: usize) { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `insert_sort` is never used [INFO] [stdout] --> src/sorting/insert_sort.rs:3:8 [INFO] [stdout] | [INFO] [stdout] 3 | pub fn insert_sort(mut vec: Vec) -> Vec [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `merge_sort` is never used [INFO] [stdout] --> src/sorting/merge_sort.rs:4:8 [INFO] [stdout] | [INFO] [stdout] 4 | pub fn merge_sort(vec: &mut [T]) { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `merge` is never used [INFO] [stdout] --> src/sorting/merge_sort.rs:14:4 [INFO] [stdout] | [INFO] [stdout] 14 | fn merge(vec: &mut [T], mid: usize) { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `quick_sort` is never used [INFO] [stdout] --> src/sorting/quick_sort.rs:1:8 [INFO] [stdout] | [INFO] [stdout] 1 | pub fn quick_sort(vec: &mut [T], left: usize, right: usize) { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `partition` is never used [INFO] [stdout] --> src/sorting/quick_sort.rs:9:4 [INFO] [stdout] | [INFO] [stdout] 9 | fn partition(vec: &mut [T], mut left: usize, mut right: usize) -> usize { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `select_sort` is never used [INFO] [stdout] --> src/sorting/select_sort.rs:3:8 [INFO] [stdout] | [INFO] [stdout] 3 | pub fn select_sort(mut vec: Vec) -> Vec [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `thread_new` is never used [INFO] [stdout] --> src/thread/mod.rs:9:8 [INFO] [stdout] | [INFO] [stdout] 9 | pub fn thread_new() { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Gender` is never used [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:7:6 [INFO] [stdout] | [INFO] [stdout] 7 | enum Gender { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Person` is never constructed [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:13:12 [INFO] [stdout] | [INFO] [stdout] 13 | pub struct Person { [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] [INFO] [stdout] [INFO] [stdout] warning: function `shared_state_concurrency` is never used [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:19:8 [INFO] [stdout] | [INFO] [stdout] 19 | pub fn shared_state_concurrency() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `message_send_rev` is never used [INFO] [stdout] --> src/thread/thread_message.rs:6:8 [INFO] [stdout] | [INFO] [stdout] 6 | pub fn message_send_rev() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: module `GLOBAL_INSTANCE` should have a snake case name [INFO] [stdout] --> src/design_patterns/singleton_pattern/mod.rs:12:5 [INFO] [stdout] | [INFO] [stdout] 12 | mod GLOBAL_INSTANCE { [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: convert the identifier to snake case: `global_instance` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_snake_case)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused `Result` that must be used [INFO] [stdout] --> src/thread/mod.rs:20:5 [INFO] [stdout] | [INFO] [stdout] 20 | handal.join(); [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: this `Result` may be an `Err` variant, which should be handled [INFO] [stdout] = note: `#[warn(unused_must_use)]` on by default [INFO] [stdout] help: use `let _ = ...` to ignore the resulting value [INFO] [stdout] | [INFO] [stdout] 20 | let _ = handal.join(); [INFO] [stdout] | +++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused `Result` that must be used [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:35:9 [INFO] [stdout] | [INFO] [stdout] 35 | i.join(); [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: this `Result` may be an `Err` variant, which should be handled [INFO] [stdout] help: use `let _ = ...` to ignore the resulting value [INFO] [stdout] | [INFO] [stdout] 35 | let _ = i.join(); [INFO] [stdout] | +++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 55 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `borrow::Borrow` [INFO] [stdout] --> src/datastruct/list.rs:1:11 [INFO] [stdout] | [INFO] [stdout] 1 | use std::{borrow::Borrow, cell::RefCell, rc::Rc}; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `do_something` is never used [INFO] [stdout] --> src/async_test/mod.rs:1:10 [INFO] [stdout] | [INFO] [stdout] 1 | async fn do_something() { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `test_async` is never used [INFO] [stdout] --> src/async_test/mod.rs:9:4 [INFO] [stdout] | [INFO] [stdout] 9 | fn test_async() { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `push_back_by_value` is never used [INFO] [stdout] --> src/datastruct/list.rs:33:12 [INFO] [stdout] | [INFO] [stdout] 17 | impl LinkedList { [INFO] [stdout] | --------------- method in this implementation [INFO] [stdout] ... [INFO] [stdout] 33 | pub fn push_back_by_value(&mut self, value: i32) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] note: the lint level is defined here [INFO] [stdout] --> src/lib.rs:2:8 [INFO] [stdout] | [INFO] [stdout] 2 | #[warn(dead_code)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variants `Female` and `Other` are never constructed [INFO] [stdout] --> src/design_patterns/singleton_pattern/mod.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 1 | enum Gender { [INFO] [stdout] | ------ variants in this enum [INFO] [stdout] 2 | Male, [INFO] [stdout] 3 | Female, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] 4 | Other, [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `name`, `age`, and `gender` are never read [INFO] [stdout] --> src/design_patterns/singleton_pattern/mod.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 6 | struct Single { [INFO] [stdout] | ------ fields in this struct [INFO] [stdout] 7 | name: String, [INFO] [stdout] | ^^^^ [INFO] [stdout] 8 | age: usize, [INFO] [stdout] | ^^^ [INFO] [stdout] 9 | gender: Gender, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: static `GLOBAL_SINGLE` is never used [INFO] [stdout] --> src/design_patterns/singleton_pattern/mod.rs:15:12 [INFO] [stdout] | [INFO] [stdout] 15 | static GLOBAL_SINGLE: Lazy> = Lazy::new(|| { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `width` and `height` are never read [INFO] [stdout] --> src/object_oriented/trait_object.rs:18:9 [INFO] [stdout] | [INFO] [stdout] 17 | pub struct Button { [INFO] [stdout] | ------ fields in this struct [INFO] [stdout] 18 | pub width: u32, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 19 | pub height: u32, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `width` and `height` are never read [INFO] [stdout] --> src/object_oriented/trait_object.rs:29:5 [INFO] [stdout] | [INFO] [stdout] 28 | pub struct SelectBox { [INFO] [stdout] | --------- fields in this struct [INFO] [stdout] 29 | width: u32, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 30 | height: u32, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bineary_search` is never used [INFO] [stdout] --> src/search/binary_search.rs:18:8 [INFO] [stdout] | [INFO] [stdout] 18 | pub fn bineary_search(vec: &Vec, target: i64) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bineary_search_01` is never used [INFO] [stdout] --> src/search/binary_search.rs:38:8 [INFO] [stdout] | [INFO] [stdout] 38 | pub fn bineary_search_01(vec: &Vec, target: i64) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bineary_search_02` is never used [INFO] [stdout] --> src/search/binary_search.rs:60:8 [INFO] [stdout] | [INFO] [stdout] 60 | pub fn bineary_search_02(vec: &Vec, target: i64) -> Result { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variants `female` and `other` are never constructed [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:9:5 [INFO] [stdout] | [INFO] [stdout] 7 | enum Gender { [INFO] [stdout] | ------ variants in this enum [INFO] [stdout] 8 | male, [INFO] [stdout] 9 | female, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] 10 | other, [INFO] [stdout] | ^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Gender` 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 `gender` are never read [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:14:5 [INFO] [stdout] | [INFO] [stdout] 13 | pub struct Person { [INFO] [stdout] | ------ fields in this struct [INFO] [stdout] 14 | name: String, [INFO] [stdout] | ^^^^ [INFO] [stdout] 15 | age: u8, [INFO] [stdout] 16 | gender: Gender, [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] [INFO] [stdout] [INFO] [stdout] warning: module `GLOBAL_INSTANCE` should have a snake case name [INFO] [stdout] --> src/design_patterns/singleton_pattern/mod.rs:12:5 [INFO] [stdout] | [INFO] [stdout] 12 | mod GLOBAL_INSTANCE { [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: convert the identifier to snake case: `global_instance` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_snake_case)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `OOP_test` should have a snake case name [INFO] [stdout] --> src/object_oriented/trait_object.rs:48:12 [INFO] [stdout] | [INFO] [stdout] 48 | pub fn OOP_test() { [INFO] [stdout] | ^^^^^^^^ help: convert the identifier to snake case: `oop_test` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `Quick_sort_test` should have a snake case name [INFO] [stdout] --> src/sorting/quick_sort.rs:28:12 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn Quick_sort_test() { [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: convert the identifier to snake case: `quick_sort_test` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused `Result` that must be used [INFO] [stdout] --> src/thread/mod.rs:20:5 [INFO] [stdout] | [INFO] [stdout] 20 | handal.join(); [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: this `Result` may be an `Err` variant, which should be handled [INFO] [stdout] = note: `#[warn(unused_must_use)]` on by default [INFO] [stdout] help: use `let _ = ...` to ignore the resulting value [INFO] [stdout] | [INFO] [stdout] 20 | let _ = handal.join(); [INFO] [stdout] | +++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused `Result` that must be used [INFO] [stdout] --> src/thread/shared_state_concurrency.rs:35:9 [INFO] [stdout] | [INFO] [stdout] 35 | i.join(); [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: this `Result` may be an `Err` variant, which should be handled [INFO] [stdout] help: use `let _ = ...` to ignore the resulting value [INFO] [stdout] | [INFO] [stdout] 35 | let _ = i.join(); [INFO] [stdout] | +++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 32 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 10.88s [INFO] running `Command { std: "docker" "inspect" "37fc0529e0c85c32f8e9b146c6ad015c786c7997fc63d013bb1a5767d0d75a87", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "37fc0529e0c85c32f8e9b146c6ad015c786c7997fc63d013bb1a5767d0d75a87", kill_on_drop: false }` [INFO] [stdout] 37fc0529e0c85c32f8e9b146c6ad015c786c7997fc63d013bb1a5767d0d75a87