[INFO] cloning repository https://github.com/BruceChar/LearnRustByExample [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/BruceChar/LearnRustByExample" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FBruceChar%2FLearnRustByExample", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FBruceChar%2FLearnRustByExample'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 2150219561f9dd455dbbc74483301654dc899e9f [INFO] checking BruceChar/LearnRustByExample against master#af4a5a13a15fa0c60e06321077ef452f769b42fd for pr-122960-3 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FBruceChar%2FLearnRustByExample" "/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/BruceChar/LearnRustByExample on toolchain af4a5a13a15fa0c60e06321077ef452f769b42fd [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+af4a5a13a15fa0c60e06321077ef452f769b42fd" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/BruceChar/LearnRustByExample [INFO] finished tweaking git repo https://github.com/BruceChar/LearnRustByExample [INFO] tweaked toml for git repo https://github.com/BruceChar/LearnRustByExample written to /workspace/builds/worker-0-tc1/source/Cargo.toml [INFO] crate git repo https://github.com/BruceChar/LearnRustByExample 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" "+af4a5a13a15fa0c60e06321077ef452f769b42fd" "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:2788e3201cd34a07e3172128adcd8b3090168a8e3bcc40d7c032b9dda1df7d1c" "/opt/rustwide/cargo-home/bin/cargo" "+af4a5a13a15fa0c60e06321077ef452f769b42fd" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 7bdc3ed358b7fbb210e5f96ad69664a0239ef84e38cd8b14a3e87e50eb83c631 [INFO] running `Command { std: "docker" "start" "-a" "7bdc3ed358b7fbb210e5f96ad69664a0239ef84e38cd8b14a3e87e50eb83c631", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "7bdc3ed358b7fbb210e5f96ad69664a0239ef84e38cd8b14a3e87e50eb83c631", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "7bdc3ed358b7fbb210e5f96ad69664a0239ef84e38cd8b14a3e87e50eb83c631", kill_on_drop: false }` [INFO] [stdout] 7bdc3ed358b7fbb210e5f96ad69664a0239ef84e38cd8b14a3e87e50eb83c631 [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:2788e3201cd34a07e3172128adcd8b3090168a8e3bcc40d7c032b9dda1df7d1c" "/opt/rustwide/cargo-home/bin/cargo" "+af4a5a13a15fa0c60e06321077ef452f769b42fd" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 4b8c6c149e473404cfd78657924587691c977c81e55faf3cd4fa5bc133242cdf [INFO] running `Command { std: "docker" "start" "-a" "4b8c6c149e473404cfd78657924587691c977c81e55faf3cd4fa5bc133242cdf", kill_on_drop: false }` [INFO] [stderr] Compiling libc v0.2.80 [INFO] [stderr] Compiling getrandom v0.1.15 [INFO] [stderr] Checking another v0.1.0 (/opt/rustwide/workdir/src/another) [INFO] [stderr] Checking rand_core v0.5.1 [INFO] [stderr] Checking rand_chacha v0.2.2 [INFO] [stderr] Checking rand v0.7.3 [INFO] [stderr] Checking anolib v0.1.0 (/opt/rustwide/workdir/anolib) [INFO] [stderr] Checking mylib v0.1.0 (/opt/rustwide/workdir/mylib) [INFO] [stderr] Checking RustByExamples v0.1.0 (/opt/rustwide/workdir) [INFO] [stderr] Checking start v0.1.0 (/opt/rustwide/workdir/start) [INFO] [stdout] warning: named argument `wid` is not used by name [INFO] [stdout] --> examples/format.rs:26:71 [INFO] [stdout] | [INFO] [stdout] 26 | println!("宽度:\n{1:*^9}\n{0:#2$.3e}\n", 3.4567, 1.23456, wid=5); [INFO] [stdout] | -- ^^^ this named argument is referred to by position in formatting string [INFO] [stdout] | | [INFO] [stdout] | this formatting argument uses named argument `wid` by position [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(named_arguments_used_positionally)]` on by default [INFO] [stdout] help: use the named argument by name to avoid ambiguity [INFO] [stdout] | [INFO] [stdout] 26 | println!("宽度:\n{1:*^9}\n{0:#wid$.3e}\n", 3.4567, 1.23456, wid=5); [INFO] [stdout] | ~~~~ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::io::stdin` [INFO] [stdout] --> examples/struct.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::io::stdin; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the item `mylib` is imported redundantly [INFO] [stdout] --> src/main.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use mylib; [INFO] [stdout] | ^^^^^ the item `mylib` is already defined by prelude [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the item `another` is imported redundantly [INFO] [stdout] --> src/main.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use another; [INFO] [stdout] | ^^^^^^^ the item `another` is already defined by prelude [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `DerefMut` [INFO] [stdout] --> examples/trait.rs:3:23 [INFO] [stdout] | [INFO] [stdout] 3 | use std::ops::{Deref, DerefMut}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::alloc::handle_alloc_error` [INFO] [stdout] --> examples/trait.rs:4:5 [INFO] [stdout] | [INFO] [stdout] 4 | use std::alloc::handle_alloc_error; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the item `anolib` is imported redundantly [INFO] [stdout] --> start/src/main.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use anolib; [INFO] [stdout] | ^^^^^^ the item `anolib` is already defined by prelude [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Unit` is never constructed [INFO] [stdout] --> examples/struct.rs:8:8 [INFO] [stdout] | [INFO] [stdout] 8 | struct Unit; [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `name` and `age` are never read [INFO] [stdout] --> examples/struct.rs:12:3 [INFO] [stdout] | [INFO] [stdout] 11 | struct Person<'a> { [INFO] [stdout] | ------ fields in this struct [INFO] [stdout] 12 | name: &'a str, [INFO] [stdout] | ^^^^ [INFO] [stdout] 13 | 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] [INFO] [stdout] [INFO] [stdout] warning: fields `p` and `sex` are never read [INFO] [stdout] --> examples/struct.rs:18:3 [INFO] [stdout] | [INFO] [stdout] 17 | struct Man<'a> { [INFO] [stdout] | --- fields in this struct [INFO] [stdout] 18 | p: Person<'a>, [INFO] [stdout] | ^ [INFO] [stdout] 19 | sex: &'a str [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Man` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `f` [INFO] [stdout] --> examples/file.rs:27:7 [INFO] [stdout] | [INFO] [stdout] 27 | let f = File::open("hello.txt").unwrap_or_else(|err| { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_f` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `function` is never used [INFO] [stdout] --> examples/mod.rs:40:4 [INFO] [stdout] | [INFO] [stdout] 40 | fn function() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 4 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 1 warning emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 1 warning emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 2 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `0` is never read [INFO] [stdout] --> examples/format.rs:57:15 [INFO] [stdout] | [INFO] [stdout] 57 | struct Deep(Structure); [INFO] [stdout] | ---- ^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | field in this struct [INFO] [stdout] | [INFO] [stdout] = note: `Deep` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] help: consider changing the field to be of unit type to suppress this warning while preserving the field numbering, or remove the field [INFO] [stdout] | [INFO] [stdout] 57 | struct Deep(()); [INFO] [stdout] | ~~ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `name` and `age` are never read [INFO] [stdout] --> examples/format.rs:61:5 [INFO] [stdout] | [INFO] [stdout] 60 | struct Person<'a> { [INFO] [stdout] | ------ fields in this struct [INFO] [stdout] 61 | name: &'a str, [INFO] [stdout] | ^^^^ [INFO] [stdout] 62 | 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] [INFO] [stdout] [INFO] [stdout] warning: 1 warning emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Receiver`, `Sender` [INFO] [stdout] --> examples/channel.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | Sender, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] 4 | Receiver [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared crate or module `io` [INFO] [stdout] --> examples/channel.rs:13:5 [INFO] [stdout] | [INFO] [stdout] 13 | io::spawn(); [INFO] [stdout] | ^^ [INFO] [stdout] | | [INFO] [stdout] | use of undeclared crate or module `io` [INFO] [stdout] | help: a builtin type with a similar name exists: `i8` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: aborting due to 1 previous error; 1 warning emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0433`. [INFO] [stdout] [INFO] [stdout] warning: 3 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> examples/inter_mutability.rs:18:45 [INFO] [stdout] | [INFO] [stdout] 18 | let b = Cons(RefCell::new(4), Rc::clone(&a)); [INFO] [stdout] | --------- ^^ expected `&Rc`, found `&List` [INFO] [stdout] | | [INFO] [stdout] | arguments to this function are incorrect [INFO] [stdout] | [INFO] [stdout] = note: expected reference `&Rc` [INFO] [stdout] found reference `&List` [INFO] [stdout] note: method defined here [INFO] [stdout] --> /rustc/af4a5a13a15fa0c60e06321077ef452f769b42fd/library/core/src/clone.rs:160:8 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> examples/inter_mutability.rs:19:45 [INFO] [stdout] | [INFO] [stdout] 19 | let c = Cons(RefCell::new(3), Rc::clone(&a)); [INFO] [stdout] | --------- ^^ expected `&Rc`, found `&List` [INFO] [stdout] | | [INFO] [stdout] | arguments to this function are incorrect [INFO] [stdout] | [INFO] [stdout] = note: expected reference `&Rc` [INFO] [stdout] found reference `&List` [INFO] [stdout] note: method defined here [INFO] [stdout] --> /rustc/af4a5a13a15fa0c60e06321077ef452f769b42fd/library/core/src/clone.rs:160:8 [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] error: could not compile `RustByExamples` (example "channel") due to 2 previous errors; 1 warning emitted [INFO] [stderr] warning: build failed, waiting for other jobs to finish... [INFO] [stdout] warning: unused variable: `e` [INFO] [stdout] --> examples/from_into.rs:34:17 [INFO] [stdout] | [INFO] [stdout] 34 | Err(e) => Person::default() [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_e` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0282]: type annotations needed for `HashMap` [INFO] [stdout] --> examples/rc.rs:21:9 [INFO] [stdout] | [INFO] [stdout] 21 | let m = HashMap::new(); [INFO] [stdout] | ^ -------------- type must be known at this point [INFO] [stdout] | [INFO] [stdout] help: consider giving `m` an explicit type, where the type for type parameter `K` is specified [INFO] [stdout] | [INFO] [stdout] 21 | let m: HashMap = HashMap::new(); [INFO] [stdout] | +++++++++++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0615]: attempted to take value of method `borrow_mut` on type `RefCell` [INFO] [stdout] --> examples/inter_mutability.rs:24:16 [INFO] [stdout] | [INFO] [stdout] 24 | *v.borrow_mut += 5; [INFO] [stdout] | ^^^^^^^^^^ method, not a field [INFO] [stdout] | [INFO] [stdout] = help: methods are immutable and cannot be assigned to [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find value `next` in this scope [INFO] [stdout] --> examples/box.rs:48:13 [INFO] [stdout] | [INFO] [stdout] 41 | next: &'a Node<'a>, [INFO] [stdout] | ------------------ a field by that name exists in `Self` [INFO] [stdout] ... [INFO] [stdout] 48 | next [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: aborting due to 3 previous errors [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0308, E0615. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0308`. [INFO] [stdout] [INFO] [stdout] warning: fields `name` and `age` are never read [INFO] [stdout] --> examples/from_into.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 2 | struct Person { [INFO] [stdout] | ------ fields in this struct [INFO] [stdout] 3 | name: String, [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)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `o` [INFO] [stdout] --> examples/trait.rs:160:9 [INFO] [stdout] | [INFO] [stdout] 160 | let o = Some(3); [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_o` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 2 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `Size` is never used [INFO] [stdout] --> examples/trait.rs:9:7 [INFO] [stdout] | [INFO] [stdout] 9 | trait Size { [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `Show` is never used [INFO] [stdout] --> examples/trait.rs:13:7 [INFO] [stdout] | [INFO] [stdout] 13 | trait Show: Debug { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Test` is never constructed [INFO] [stdout] --> examples/trait.rs:21:8 [INFO] [stdout] | [INFO] [stdout] 21 | struct Test { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new` is never used [INFO] [stdout] --> examples/trait.rs:35:8 [INFO] [stdout] | [INFO] [stdout] 34 | impl Test { [INFO] [stdout] | --------- associated function in this implementation [INFO] [stdout] 35 | fn new() -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `demo_ref` is never used [INFO] [stdout] --> examples/trait.rs:43:4 [INFO] [stdout] | [INFO] [stdout] 43 | fn demo_ref(t:&T) where T:Debug { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `show_type` is never used [INFO] [stdout] --> examples/trait.rs:47:4 [INFO] [stdout] | [INFO] [stdout] 47 | fn show_type(_v: &T) { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Counter` is never constructed [INFO] [stdout] --> examples/trait.rs:52:8 [INFO] [stdout] | [INFO] [stdout] 52 | struct Counter { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] error: could not compile `RustByExamples` (example "inter_mutability") due to 4 previous errors [INFO] [stdout] warning: unused variable: `names` [INFO] [stdout] --> examples/iterator.rs:164:9 [INFO] [stdout] | [INFO] [stdout] 164 | let names = ["Bruce", "WTF"]; [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_names` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 10 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> examples/iterator.rs:147:9 [INFO] [stdout] | [INFO] [stdout] 147 | let mut names = vec!["Bruce", "Chal", "Grooy"]; [INFO] [stdout] | ----^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_mut)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> examples/iterator.rs:156:9 [INFO] [stdout] | [INFO] [stdout] 156 | let mut names = ["Bruce", "Chal", "Grooy"]; [INFO] [stdout] | ----^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> examples/iterator.rs:179:9 [INFO] [stdout] | [INFO] [stdout] 179 | let mut fib = Fibonacci::new(); [INFO] [stdout] | ----^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> examples/iterator.rs:186:9 [INFO] [stdout] | [INFO] [stdout] 186 | let mut fib = Fibonacci::new(); [INFO] [stdout] | ----^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `putline` [INFO] [stdout] --> examples/box.rs:60:9 [INFO] [stdout] | [INFO] [stdout] 60 | let putline = || print!("\n"); [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_putline` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> examples/box.rs:64:9 [INFO] [stdout] | [INFO] [stdout] 64 | let n = Node::new(); [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> examples/iterator.rs:200:9 [INFO] [stdout] | [INFO] [stdout] 200 | let mut word = Words::new("Hello Bruce I am WTFUCKER"); [INFO] [stdout] | ----^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `print_type` is never used [INFO] [stdout] --> examples/iterator.rs:16:4 [INFO] [stdout] | [INFO] [stdout] 16 | fn print_type(_: &T) { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Fibonacci` is never constructed [INFO] [stdout] --> examples/iterator.rs:21:8 [INFO] [stdout] | [INFO] [stdout] 21 | struct Fibonacci { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `new` is never used [INFO] [stdout] --> examples/iterator.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 36 | impl Fibonacci { [INFO] [stdout] | -------------- associated function in this implementation [INFO] [stdout] 37 | fn new() -> Self { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `iter` is never used [INFO] [stdout] --> examples/iterator.rs:126:8 [INFO] [stdout] | [INFO] [stdout] 125 | impl<'a> Words<'a> { [INFO] [stdout] | ------------------ method in this implementation [INFO] [stdout] 126 | fn iter(&'a self) -> IterHelper<'a> { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `exam_run` is never used [INFO] [stdout] --> examples/iterator.rs:146:4 [INFO] [stdout] | [INFO] [stdout] 146 | fn exam_run() { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: aborting due to 1 previous error; 2 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0425`. [INFO] [stdout] [INFO] [stdout] error: aborting due to 1 previous error [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0282`. [INFO] [stdout] [INFO] [stdout] warning: the item `anolib` is imported redundantly [INFO] [stdout] --> start/src/main.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use anolib; [INFO] [stdout] | ^^^^^^ the item `anolib` is already defined by prelude [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 11 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the item `mylib` is imported redundantly [INFO] [stdout] --> src/main.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use mylib; [INFO] [stdout] | ^^^^^ the item `mylib` is already defined by prelude [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the item `another` is imported redundantly [INFO] [stdout] --> src/main.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use another; [INFO] [stdout] | ^^^^^^^ the item `another` is already defined by prelude [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `super::*` [INFO] [stdout] --> src/main.rs:21:7 [INFO] [stdout] | [INFO] [stdout] 21 | use super::*; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: if this is a test module, consider adding a `#[cfg(test)]` to the containing module [INFO] [stdout] --> src/main.rs:20:1 [INFO] [stdout] | [INFO] [stdout] 20 | mod tests{ [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] error: could not compile `RustByExamples` (example "box") due to 2 previous errors; 2 warnings emitted [INFO] [stdout] warning: 1 warning emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] error: could not compile `RustByExamples` (example "rc") due to 2 previous errors [INFO] [stdout] warning: function `print` is never used [INFO] [stdout] --> src/main.rs:5:4 [INFO] [stdout] | [INFO] [stdout] 5 | fn print(a: i32) -> i32 { [INFO] [stdout] | ^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `name`, `age`, and `subject` are never read [INFO] [stdout] --> examples/struct_inherit.rs:45:5 [INFO] [stdout] | [INFO] [stdout] 43 | struct Teacher { [INFO] [stdout] | ------- fields in this struct [INFO] [stdout] 44 | apple_eater: AppleEater, [INFO] [stdout] 45 | name: String, [INFO] [stdout] | ^^^^ [INFO] [stdout] 46 | age: u16, [INFO] [stdout] | ^^^ [INFO] [stdout] 47 | subject: String, [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Student` is never constructed [INFO] [stdout] --> examples/struct_inherit.rs:50:8 [INFO] [stdout] | [INFO] [stdout] 50 | struct Student { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `eat_granny_smith` is never used [INFO] [stdout] --> examples/struct_inherit.rs:20:16 [INFO] [stdout] | [INFO] [stdout] 7 | impl AppleEater { [INFO] [stdout] | --------------- method in this implementation [INFO] [stdout] ... [INFO] [stdout] 20 | pub fn eat_granny_smith(&mut self) { self.granny_smiths += 1; } [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: method `eat_granny_smith` is never used [INFO] [stdout] --> examples/struct_inherit.rs:34:12 [INFO] [stdout] | [INFO] [stdout] 31 | pub trait AsMutAppleEater: AsAppleEater { [INFO] [stdout] | --------------- method in this trait [INFO] [stdout] ... [INFO] [stdout] 34 | fn eat_granny_smith(&mut self) [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 4 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: cannot add a float to an integer [INFO] [stdout] --> examples/recursive_type.rs:35:31 [INFO] [stdout] | [INFO] [stdout] 35 | println!("{:?} {:?}", e, c+d); [INFO] [stdout] | ^ no implementation for `{integer} + {float}` [INFO] [stdout] | [INFO] [stdout] = help: the trait `Add<{float}>` is not implemented for `{integer}`, which is required by `Cup<{integer}>: Add<_>` [INFO] [stdout] = help: the following other types implement trait `Add`: [INFO] [stdout] <&'a f32 as Add> [INFO] [stdout] <&'a f64 as Add> [INFO] [stdout] <&'a i128 as Add> [INFO] [stdout] <&'a i16 as Add> [INFO] [stdout] <&'a i32 as Add> [INFO] [stdout] <&'a i64 as Add> [INFO] [stdout] <&'a i8 as Add> [INFO] [stdout] <&'a isize as Add> [INFO] [stdout] and 48 others [INFO] [stdout] note: required for `Cup<{integer}>` to implement `Add>` [INFO] [stdout] --> examples/recursive_type.rs:19:12 [INFO] [stdout] | [INFO] [stdout] 19 | impl Add> for Cup [INFO] [stdout] | ^^^^^^^^^^^ ^^^^^^ [INFO] [stdout] 20 | where A: Add [INFO] [stdout] | ------ unsatisfied trait bound introduced here [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `UsState` is never used [INFO] [stdout] --> examples/match.rs:3:6 [INFO] [stdout] | [INFO] [stdout] 3 | enum UsState { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enum `Coin` is never used [INFO] [stdout] --> examples/match.rs:10:6 [INFO] [stdout] | [INFO] [stdout] 10 | enum Coin { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `value_in_cents` is never used [INFO] [stdout] --> examples/match.rs:17:4 [INFO] [stdout] | [INFO] [stdout] 17 | fn value_in_cents(coin: Coin) -> u8 { [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 4 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `other_bind` is never used [INFO] [stdout] --> examples/match.rs:52:4 [INFO] [stdout] | [INFO] [stdout] 52 | fn other_bind(coin: Coin) { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `plus_one` is never used [INFO] [stdout] --> examples/match.rs:63:4 [INFO] [stdout] | [INFO] [stdout] 63 | fn plus_one(x: Option) -> Option { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `count_without_quarter` is never used [INFO] [stdout] --> examples/match.rs:71:4 [INFO] [stdout] | [INFO] [stdout] 71 | fn count_without_quarter(coins: &Vec) -> i32 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `count_while` is never used [INFO] [stdout] --> examples/match.rs:86:4 [INFO] [stdout] | [INFO] [stdout] 86 | fn count_while(coins: &mut Vec) -> i32 { [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: aborting due to 1 previous error [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0277`. [INFO] [stdout] [INFO] [stdout] warning: 7 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] error: could not compile `RustByExamples` (example "recursive_type") due to 2 previous errors [INFO] running `Command { std: "docker" "inspect" "4b8c6c149e473404cfd78657924587691c977c81e55faf3cd4fa5bc133242cdf", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "4b8c6c149e473404cfd78657924587691c977c81e55faf3cd4fa5bc133242cdf", kill_on_drop: false }` [INFO] [stdout] 4b8c6c149e473404cfd78657924587691c977c81e55faf3cd4fa5bc133242cdf [INFO] checking BruceChar/LearnRustByExample against try#36dbcaee1a55543dfc181be52a69d99ff46ff62f for pr-122960-3 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FBruceChar%2FLearnRustByExample" "/workspace/builds/worker-0-tc2/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-0-tc2/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/BruceChar/LearnRustByExample on toolchain 36dbcaee1a55543dfc181be52a69d99ff46ff62f [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+36dbcaee1a55543dfc181be52a69d99ff46ff62f" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/BruceChar/LearnRustByExample [INFO] finished tweaking git repo https://github.com/BruceChar/LearnRustByExample [INFO] tweaked toml for git repo https://github.com/BruceChar/LearnRustByExample written to /workspace/builds/worker-0-tc2/source/Cargo.toml [INFO] crate git repo https://github.com/BruceChar/LearnRustByExample 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" "+36dbcaee1a55543dfc181be52a69d99ff46ff62f" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-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:2788e3201cd34a07e3172128adcd8b3090168a8e3bcc40d7c032b9dda1df7d1c" "/opt/rustwide/cargo-home/bin/cargo" "+36dbcaee1a55543dfc181be52a69d99ff46ff62f" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 9cfa010589a35f97e526fd2fc87ed7c692553e0ba4062d3159ace9d3bbd6485e [INFO] running `Command { std: "docker" "start" "-a" "9cfa010589a35f97e526fd2fc87ed7c692553e0ba4062d3159ace9d3bbd6485e", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "9cfa010589a35f97e526fd2fc87ed7c692553e0ba4062d3159ace9d3bbd6485e", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "9cfa010589a35f97e526fd2fc87ed7c692553e0ba4062d3159ace9d3bbd6485e", kill_on_drop: false }` [INFO] [stdout] 9cfa010589a35f97e526fd2fc87ed7c692553e0ba4062d3159ace9d3bbd6485e [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-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=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:2788e3201cd34a07e3172128adcd8b3090168a8e3bcc40d7c032b9dda1df7d1c" "/opt/rustwide/cargo-home/bin/cargo" "+36dbcaee1a55543dfc181be52a69d99ff46ff62f" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 66f3b8c1cd1f28ddcaafabc9da147545c8a15c7a55f34c9fa9263bd838f03f98 [INFO] running `Command { std: "docker" "start" "-a" "66f3b8c1cd1f28ddcaafabc9da147545c8a15c7a55f34c9fa9263bd838f03f98", kill_on_drop: false }` [INFO] [stderr] Copying to /tmp/fixit [INFO] [stderr] skipping non-2021 edition `2018` [INFO] running `Command { std: "docker" "inspect" "66f3b8c1cd1f28ddcaafabc9da147545c8a15c7a55f34c9fa9263bd838f03f98", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "66f3b8c1cd1f28ddcaafabc9da147545c8a15c7a55f34c9fa9263bd838f03f98", kill_on_drop: false }` [INFO] [stdout] 66f3b8c1cd1f28ddcaafabc9da147545c8a15c7a55f34c9fa9263bd838f03f98