[INFO] cloning repository https://github.com/leecobaby/study-rust [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/leecobaby/study-rust" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fleecobaby%2Fstudy-rust", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fleecobaby%2Fstudy-rust'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] d7cb5e178d0d2d6794201af8b33d067ab635bef3 [INFO] testing leecobaby/study-rust against master#562dee4820c458d823175268e41601d4c060588a for pr-154210-1 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fleecobaby%2Fstudy-rust" "/workspace/builds/worker-2-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-2-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/leecobaby/study-rust [INFO] finished tweaking git repo https://github.com/leecobaby/study-rust [INFO] tweaked toml for git repo https://github.com/leecobaby/study-rust written to /workspace/builds/worker-2-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/leecobaby/study-rust on toolchain 562dee4820c458d823175268e41601d4c060588a [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+562dee4820c458d823175268e41601d4c060588a" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] crate git repo https://github.com/leecobaby/study-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" "+562dee4820c458d823175268e41601d4c060588a" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] warning: unused manifest key: profiles [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded rand v0.5.6 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-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" "+562dee4820c458d823175268e41601d4c060588a" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] bb3976d5ee4cdfa236387574988c4f570b7f7d906db798be0a0f528485b70127 [INFO] running `Command { std: "docker" "start" "-a" "bb3976d5ee4cdfa236387574988c4f570b7f7d906db798be0a0f528485b70127", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "bb3976d5ee4cdfa236387574988c4f570b7f7d906db798be0a0f528485b70127", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "bb3976d5ee4cdfa236387574988c4f570b7f7d906db798be0a0f528485b70127", kill_on_drop: false }` [INFO] [stdout] bb3976d5ee4cdfa236387574988c4f570b7f7d906db798be0a0f528485b70127 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-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" "+562dee4820c458d823175268e41601d4c060588a" "build" "--frozen" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] d29e0fd54094faf4dd9822ccf664fdefbd7f1b7f8feee2a3d98fc16f0b8bc21f [INFO] running `Command { std: "docker" "start" "-a" "d29e0fd54094faf4dd9822ccf664fdefbd7f1b7f8feee2a3d98fc16f0b8bc21f", kill_on_drop: false }` [INFO] [stderr] warning: unused manifest key: profiles [INFO] [stderr] Compiling libc v0.2.139 [INFO] [stderr] Compiling rand_core v0.4.2 [INFO] [stderr] Compiling rand_core v0.3.1 [INFO] [stderr] Compiling rand v0.5.6 [INFO] [stderr] Compiling study_rust v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] error[E0428]: the name `generic` is defined multiple times [INFO] [stdout] --> src/bin/19-3.rs:52:1 [INFO] [stdout] | [INFO] [stdout] 47 | fn generic(t: T) { [INFO] [stdout] | ------------------- previous definition of the value `generic` here [INFO] [stdout] ... [INFO] [stdout] 52 | fn generic(t: T) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ `generic` redefined here [INFO] [stdout] | [INFO] [stdout] = note: `generic` must be defined only once in the value namespace of this module [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0428]: the name `generic` is defined multiple times [INFO] [stdout] --> src/bin/19-3.rs:57:1 [INFO] [stdout] | [INFO] [stdout] 47 | fn generic(t: T) { [INFO] [stdout] | ------------------- previous definition of the value `generic` here [INFO] [stdout] ... [INFO] [stdout] 57 | fn generic(t: &T) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ `generic` redefined here [INFO] [stdout] | [INFO] [stdout] = note: `generic` must be defined only once in the value namespace of this module [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0252]: the name `io` is defined multiple times [INFO] [stdout] --> src/bin/7-5.rs:21:15 [INFO] [stdout] | [INFO] [stdout] 18 | use std::{cmp::Ordering, io}; [INFO] [stdout] | -- previous import of the module `io` here [INFO] [stdout] ... [INFO] [stdout] 21 | use std::io::{self, Write}; [INFO] [stdout] | ^^^^-- [INFO] [stdout] | | [INFO] [stdout] | `io` reimported here [INFO] [stdout] | help: remove unnecessary import [INFO] [stdout] | [INFO] [stdout] = note: `io` must be defined only once in the type namespace of this module [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> src/bin/19-3.rs:38:13 [INFO] [stdout] | [INFO] [stdout] 38 | fn bar() -> ! { [INFO] [stdout] | --- ^ expected `!`, found `()` [INFO] [stdout] | | [INFO] [stdout] | implicitly returns `()` as its body has no tail or `return` expression [INFO] [stdout] | [INFO] [stdout] = note: expected type `!` [INFO] [stdout] found unit type `()` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `f` [INFO] [stdout] --> src/bin/19-3.rs:11:9 [INFO] [stdout] | [INFO] [stdout] 11 | let f: Thunk = Box::new(|| println!("hi")); [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_f` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `f` [INFO] [stdout] --> src/bin/19-3.rs:16:20 [INFO] [stdout] | [INFO] [stdout] 16 | fn takes_long_type(f: Thunk) { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_f` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `t` [INFO] [stdout] --> src/bin/19-3.rs:47:15 [INFO] [stdout] | [INFO] [stdout] 47 | fn generic(t: T) { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_t` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `t` [INFO] [stdout] --> src/bin/19-3.rs:52:22 [INFO] [stdout] | [INFO] [stdout] 52 | fn generic(t: T) { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_t` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `t` [INFO] [stdout] --> src/bin/19-3.rs:57:23 [INFO] [stdout] | [INFO] [stdout] 57 | fn generic(t: &T) { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_t` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0308, E0428. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0308`. [INFO] [stdout] [INFO] [stdout] warning: unused import: `rand::Rng` [INFO] [stdout] --> src/bin/7-5.rs:14:5 [INFO] [stdout] | [INFO] [stdout] 14 | use rand::Rng; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::collections::HashMap` [INFO] [stdout] --> src/bin/7-5.rs:15:5 [INFO] [stdout] | [INFO] [stdout] 15 | use std::collections::HashMap; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `cmp::Ordering` and `io` [INFO] [stdout] --> src/bin/7-5.rs:18:11 [INFO] [stdout] | [INFO] [stdout] 18 | use std::{cmp::Ordering, io}; [INFO] [stdout] | ^^^^^^^^^^^^^ ^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Write` and `self` [INFO] [stdout] --> src/bin/7-5.rs:21:15 [INFO] [stdout] | [INFO] [stdout] 21 | use std::io::{self, Write}; [INFO] [stdout] | ^^^^ ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] error: could not compile `study_rust` (bin "19-3") due to 3 previous errors; 5 warnings emitted [INFO] [stderr] warning: build failed, waiting for other jobs to finish... [INFO] [stdout] warning: unused import: `std::fmt::Result` [INFO] [stdout] --> src/bin/7-4.rs:26:5 [INFO] [stdout] | [INFO] [stdout] 26 | use std::fmt::Result; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::io::Result as IoResult` [INFO] [stdout] --> src/bin/7-4.rs:27:5 [INFO] [stdout] | [INFO] [stdout] 27 | use std::io::Result as IoResult; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0601]: `main` function not found in crate `7_5` [INFO] [stdout] --> src/bin/7-5.rs:21:28 [INFO] [stdout] | [INFO] [stdout] 21 | use std::io::{self, Write}; [INFO] [stdout] | ^ consider adding a `main` function to `src/bin/7-5.rs` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0601]: `main` function not found in crate `7_4` [INFO] [stdout] --> src/bin/7-4.rs:27:33 [INFO] [stdout] | [INFO] [stdout] 27 | use std::io::Result as IoResult; [INFO] [stdout] | ^ consider adding a `main` function to `src/bin/7-4.rs` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0252, E0601. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0252`. [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0601`. [INFO] [stdout] [INFO] [stderr] error: could not compile `study_rust` (bin "7-5") due to 2 previous errors; 4 warnings emitted [INFO] [stderr] error: could not compile `study_rust` (bin "7-4") due to 1 previous error; 2 warnings emitted [INFO] [stdout] error[E0601]: `main` function not found in crate `17_1` [INFO] [stdout] --> src/bin/17-1.rs:2:18 [INFO] [stdout] | [INFO] [stdout] 2 | // 通过泛型约束,可以实现多态 [INFO] [stdout] | ^ consider adding a `main` function to `src/bin/17-1.rs` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0601`. [INFO] [stdout] [INFO] [stderr] error: could not compile `study_rust` (bin "17-1") due to 1 previous error [INFO] [stdout] error[E0601]: `main` function not found in crate `11_6` [INFO] [stdout] --> src/bin/11-6.rs:34:2 [INFO] [stdout] | [INFO] [stdout] 34 | } [INFO] [stdout] | ^ consider adding a `main` function to `src/bin/11-6.rs` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `area` is never used [INFO] [stdout] --> src/bin/5-3.rs:13:8 [INFO] [stdout] | [INFO] [stdout] 12 | impl Rectangle { [INFO] [stdout] | -------------- method in this implementation [INFO] [stdout] 13 | fn area(&self) -> u32 { [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0601`. [INFO] [stdout] [INFO] [stderr] error: could not compile `study_rust` (bin "11-6") due to 1 previous error [INFO] running `Command { std: "docker" "inspect" "d29e0fd54094faf4dd9822ccf664fdefbd7f1b7f8feee2a3d98fc16f0b8bc21f", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "d29e0fd54094faf4dd9822ccf664fdefbd7f1b7f8feee2a3d98fc16f0b8bc21f", kill_on_drop: false }` [INFO] [stdout] d29e0fd54094faf4dd9822ccf664fdefbd7f1b7f8feee2a3d98fc16f0b8bc21f