[INFO] cloning repository https://github.com/mirite/rust-parser [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/mirite/rust-parser" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fmirite%2Frust-parser", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fmirite%2Frust-parser'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] b5d7c26a1f106bd2cf3e937d0149ffd9a66c07e8 [INFO] checking mirite/rust-parser against master#0c478fdfe138a8b09744798c85fe2be657768b00 for pr-139419 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fmirite%2Frust-parser" "/workspace/builds/worker-1-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-1-tc1/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/mirite/rust-parser on toolchain 0c478fdfe138a8b09744798c85fe2be657768b00 [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+0c478fdfe138a8b09744798c85fe2be657768b00" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/mirite/rust-parser [INFO] finished tweaking git repo https://github.com/mirite/rust-parser [INFO] tweaked toml for git repo https://github.com/mirite/rust-parser written to /workspace/builds/worker-1-tc1/source/Cargo.toml [INFO] crate git repo https://github.com/mirite/rust-parser 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" "+0c478fdfe138a8b09744798c85fe2be657768b00" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Blocking waiting for file lock on package cache [INFO] [stderr] Blocking waiting for file lock on package cache [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-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:b0b074c097205a61b89e8ad263052f976b2b332c4dc5f02aef1fe52501660d6e" "/opt/rustwide/cargo-home/bin/cargo" "+0c478fdfe138a8b09744798c85fe2be657768b00" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 218c6709fdf84735a9d18e8f446cc96e102de8c23dd287a0e329463e8952885e [INFO] running `Command { std: "docker" "start" "-a" "218c6709fdf84735a9d18e8f446cc96e102de8c23dd287a0e329463e8952885e", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "218c6709fdf84735a9d18e8f446cc96e102de8c23dd287a0e329463e8952885e", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "218c6709fdf84735a9d18e8f446cc96e102de8c23dd287a0e329463e8952885e", kill_on_drop: false }` [INFO] [stdout] 218c6709fdf84735a9d18e8f446cc96e102de8c23dd287a0e329463e8952885e [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-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:b0b074c097205a61b89e8ad263052f976b2b332c4dc5f02aef1fe52501660d6e" "/opt/rustwide/cargo-home/bin/cargo" "+0c478fdfe138a8b09744798c85fe2be657768b00" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 3d737bc7b2eaf419ca2c16ecaec10f620228570748b9d1198e72c180e046930d [INFO] running `Command { std: "docker" "start" "-a" "3d737bc7b2eaf419ca2c16ecaec10f620228570748b9d1198e72c180e046930d", kill_on_drop: false }` [INFO] [stderr] Checking rust-parser v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] error[E0596]: cannot borrow `last_open.children` as mutable, as it is behind a `&` reference [INFO] [stdout] --> src/tree.rs:25:13 [INFO] [stdout] | [INFO] [stdout] 25 | last_open.children.push(node); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ `last_open` is a `&` reference, so the data it refers to cannot be borrowed as mutable [INFO] [stdout] | [INFO] [stdout] help: consider specifying this binding's type [INFO] [stdout] | [INFO] [stdout] 24 | let last_open: &mut &mut Tree = open_tags.last().unwrap(); [INFO] [stdout] | ++++++++++++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0515]: cannot return reference to local variable `node` [INFO] [stdout] --> src/tree.rs:27:9 [INFO] [stdout] | [INFO] [stdout] 27 | &mut node [INFO] [stdout] | ^^^^^^^^^ returns a reference to data owned by the current function [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0382]: borrow of moved value: `node` [INFO] [stdout] --> src/tree.rs:27:9 [INFO] [stdout] | [INFO] [stdout] 17 | let mut node = Tree { [INFO] [stdout] | -------- move occurs because `node` has type `Tree`, which does not implement the `Copy` trait [INFO] [stdout] ... [INFO] [stdout] 22 | tree.push(node); [INFO] [stdout] | ---- value moved here [INFO] [stdout] ... [INFO] [stdout] 25 | last_open.children.push(node); [INFO] [stdout] | ---- value moved here [INFO] [stdout] 26 | } [INFO] [stdout] 27 | &mut node [INFO] [stdout] | ^^^^^^^^^ value borrowed here after move [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0596]: cannot borrow `add_to_last_open` as mutable, as it is not declared as mutable [INFO] [stdout] --> src/tree.rs:16:9 [INFO] [stdout] | [INFO] [stdout] 16 | let add_to_last_open = |token: &Token| -> &mut Tree { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ not mutable [INFO] [stdout] ... [INFO] [stdout] 22 | tree.push(node); [INFO] [stdout] | ---- calling `add_to_last_open` requires mutable binding due to mutable borrow of `tree` [INFO] [stdout] ... [INFO] [stdout] 35 | add_to_last_open(token); [INFO] [stdout] | ---------------- cannot borrow as mutable [INFO] [stdout] ... [INFO] [stdout] 38 | add_to_last_open(token); [INFO] [stdout] | ---------------- cannot borrow as mutable [INFO] [stdout] ... [INFO] [stdout] 41 | let new_tree = add_to_last_open(token); [INFO] [stdout] | ---------------- cannot borrow as mutable [INFO] [stdout] ... [INFO] [stdout] 57 | add_to_last_open(token); [INFO] [stdout] | ---------------- cannot borrow as mutable [INFO] [stdout] | [INFO] [stdout] help: consider changing this to be mutable [INFO] [stdout] | [INFO] [stdout] 16 | let mut add_to_last_open = |token: &Token| -> &mut Tree { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0502]: cannot borrow `open_tags` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/tree.rs:42:21 [INFO] [stdout] | [INFO] [stdout] 16 | let add_to_last_open = |token: &Token| -> &mut Tree { [INFO] [stdout] | ---------------------------- immutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 21 | if open_tags.len() == 0 { [INFO] [stdout] | --------- first borrow occurs due to use of `open_tags` in closure [INFO] [stdout] ... [INFO] [stdout] 42 | open_tags.push(new_tree); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ mutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 57 | add_to_last_open(token); [INFO] [stdout] | ---------------- immutable borrow later used here [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0502]: cannot borrow `open_tags` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/tree.rs:48:29 [INFO] [stdout] | [INFO] [stdout] 16 | let add_to_last_open = |token: &Token| -> &mut Tree { [INFO] [stdout] | ---------------------------- immutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 21 | if open_tags.len() == 0 { [INFO] [stdout] | --------- first borrow occurs due to use of `open_tags` in closure [INFO] [stdout] ... [INFO] [stdout] 48 | open_tags.remove(i); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ mutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 57 | add_to_last_open(token); [INFO] [stdout] | ---------------- immutable borrow later used here [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0382, E0502, E0515, E0596. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0382`. [INFO] [stdout] [INFO] [stdout] error[E0596]: cannot borrow `last_open.children` as mutable, as it is behind a `&` reference [INFO] [stdout] --> src/tree.rs:25:13 [INFO] [stdout] | [INFO] [stdout] 25 | last_open.children.push(node); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ `last_open` is a `&` reference, so the data it refers to cannot be borrowed as mutable [INFO] [stdout] | [INFO] [stdout] help: consider specifying this binding's type [INFO] [stdout] | [INFO] [stdout] 24 | let last_open: &mut &mut Tree = open_tags.last().unwrap(); [INFO] [stdout] | ++++++++++++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0515]: cannot return reference to local variable `node` [INFO] [stdout] --> src/tree.rs:27:9 [INFO] [stdout] | [INFO] [stdout] 27 | &mut node [INFO] [stdout] | ^^^^^^^^^ returns a reference to data owned by the current function [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0382]: borrow of moved value: `node` [INFO] [stdout] --> src/tree.rs:27:9 [INFO] [stdout] | [INFO] [stdout] 17 | let mut node = Tree { [INFO] [stdout] | -------- move occurs because `node` has type `Tree`, which does not implement the `Copy` trait [INFO] [stdout] ... [INFO] [stdout] 22 | tree.push(node); [INFO] [stdout] | ---- value moved here [INFO] [stdout] ... [INFO] [stdout] 25 | last_open.children.push(node); [INFO] [stdout] | ---- value moved here [INFO] [stdout] 26 | } [INFO] [stdout] 27 | &mut node [INFO] [stdout] | ^^^^^^^^^ value borrowed here after move [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0596]: cannot borrow `add_to_last_open` as mutable, as it is not declared as mutable [INFO] [stdout] --> src/tree.rs:16:9 [INFO] [stdout] | [INFO] [stdout] 16 | let add_to_last_open = |token: &Token| -> &mut Tree { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ not mutable [INFO] [stdout] ... [INFO] [stdout] 22 | tree.push(node); [INFO] [stdout] | ---- calling `add_to_last_open` requires mutable binding due to mutable borrow of `tree` [INFO] [stdout] ... [INFO] [stdout] 35 | add_to_last_open(token); [INFO] [stdout] | ---------------- cannot borrow as mutable [INFO] [stdout] ... [INFO] [stdout] 38 | add_to_last_open(token); [INFO] [stdout] | ---------------- cannot borrow as mutable [INFO] [stdout] ... [INFO] [stdout] 41 | let new_tree = add_to_last_open(token); [INFO] [stdout] | ---------------- cannot borrow as mutable [INFO] [stdout] ... [INFO] [stdout] 57 | add_to_last_open(token); [INFO] [stdout] | ---------------- cannot borrow as mutable [INFO] [stdout] | [INFO] [stdout] help: consider changing this to be mutable [INFO] [stdout] | [INFO] [stdout] 16 | let mut add_to_last_open = |token: &Token| -> &mut Tree { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0502]: cannot borrow `open_tags` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/tree.rs:42:21 [INFO] [stdout] | [INFO] [stdout] 16 | let add_to_last_open = |token: &Token| -> &mut Tree { [INFO] [stdout] | ---------------------------- immutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 21 | if open_tags.len() == 0 { [INFO] [stdout] | --------- first borrow occurs due to use of `open_tags` in closure [INFO] [stdout] ... [INFO] [stdout] 42 | open_tags.push(new_tree); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ mutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 57 | add_to_last_open(token); [INFO] [stdout] | ---------------- immutable borrow later used here [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0502]: cannot borrow `open_tags` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/tree.rs:48:29 [INFO] [stdout] | [INFO] [stdout] 16 | let add_to_last_open = |token: &Token| -> &mut Tree { [INFO] [stdout] | ---------------------------- immutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 21 | if open_tags.len() == 0 { [INFO] [stdout] | --------- first borrow occurs due to use of `open_tags` in closure [INFO] [stdout] ... [INFO] [stdout] 48 | open_tags.remove(i); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ mutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 57 | add_to_last_open(token); [INFO] [stdout] | ---------------- immutable borrow later used here [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] error: could not compile `rust-parser` (bin "rust-parser") due to 6 previous errors [INFO] [stderr] warning: build failed, waiting for other jobs to finish... [INFO] [stdout] Some errors have detailed explanations: E0382, E0502, E0515, E0596. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0382`. [INFO] [stdout] [INFO] [stderr] error: could not compile `rust-parser` (bin "rust-parser" test) due to 6 previous errors [INFO] running `Command { std: "docker" "inspect" "3d737bc7b2eaf419ca2c16ecaec10f620228570748b9d1198e72c180e046930d", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "3d737bc7b2eaf419ca2c16ecaec10f620228570748b9d1198e72c180e046930d", kill_on_drop: false }` [INFO] [stdout] 3d737bc7b2eaf419ca2c16ecaec10f620228570748b9d1198e72c180e046930d