[INFO] cloning repository https://github.com/Darktrop/hdfs-cli [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/Darktrop/hdfs-cli" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FDarktrop%2Fhdfs-cli", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FDarktrop%2Fhdfs-cli'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] c14058ec9e4efd62efe2bf5c85502f6419621342 [INFO] checking Darktrop/hdfs-cli/c14058ec9e4efd62efe2bf5c85502f6419621342 against master#ff1737bb00913444173658b4e0b274fd79aabf66 for pr-132712-1 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FDarktrop%2Fhdfs-cli" "/workspace/builds/worker-7-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-7-tc1/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/Darktrop/hdfs-cli on toolchain ff1737bb00913444173658b4e0b274fd79aabf66 [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+ff1737bb00913444173658b4e0b274fd79aabf66" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/Darktrop/hdfs-cli [INFO] finished tweaking git repo https://github.com/Darktrop/hdfs-cli [INFO] tweaked toml for git repo https://github.com/Darktrop/hdfs-cli written to /workspace/builds/worker-7-tc1/source/Cargo.toml [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+ff1737bb00913444173658b4e0b274fd79aabf66" "generate-lockfile" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Updating crates.io index [INFO] [stderr] Locking 86 packages to latest compatible versions [INFO] [stderr] Adding clap v2.34.0 (available: v4.5.21) [INFO] [stderr] Adding dirs v1.0.5 (available: v5.0.1) [INFO] [stderr] Adding env_logger v0.5.13 (available: v0.11.5) [INFO] [stderr] Adding glob v0.2.11 (available: v0.3.1) [INFO] [stderr] Adding itertools v0.7.11 (available: v0.13.0) [INFO] [stderr] Adding nix v0.11.1 (available: v0.29.0) [INFO] [stderr] Adding quick-xml v0.13.3 (available: v0.37.1) [INFO] [stderr] Adding rand v0.5.6 (available: v0.8.5) [INFO] [stderr] Adding toml v0.4.10 (available: v0.8.19) [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+ff1737bb00913444173658b4e0b274fd79aabf66" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] warning: /workspace/builds/worker-7-tc1/source/hdfs-cmd/Cargo.toml: no edition set: defaulting to the 2015 edition while the latest is 2021 [INFO] [stderr] warning: /workspace/builds/worker-7-tc1/source/walk/Cargo.toml: no edition set: defaulting to the 2015 edition while the latest is 2021 [INFO] [stderr] warning: /workspace/builds/worker-7-tc1/source/fs_test/Cargo.toml: no edition set: defaulting to the 2015 edition while the latest is 2021 [INFO] [stderr] warning: /workspace/builds/worker-7-tc1/source/hdfs/Cargo.toml: no edition set: defaulting to the 2015 edition while the latest is 2021 [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded quick-xml v0.13.3 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-7-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-7-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:4a844ea9eb2546a2d2c7022eacef16ef2e8229c7fbb2c7d4d55a9ceca922f72d" "/opt/rustwide/cargo-home/bin/cargo" "+ff1737bb00913444173658b4e0b274fd79aabf66" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 21ab3573210f2d1a1912805f9c2378d983e49515536185e9e3780089cc4dc386 [INFO] running `Command { std: "docker" "start" "-a" "21ab3573210f2d1a1912805f9c2378d983e49515536185e9e3780089cc4dc386", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "21ab3573210f2d1a1912805f9c2378d983e49515536185e9e3780089cc4dc386", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "21ab3573210f2d1a1912805f9c2378d983e49515536185e9e3780089cc4dc386", kill_on_drop: false }` [INFO] [stdout] 21ab3573210f2d1a1912805f9c2378d983e49515536185e9e3780089cc4dc386 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-7-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-7-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=allow" "-e" "RUSTDOCFLAGS=--cap-lints=allow" "-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:4a844ea9eb2546a2d2c7022eacef16ef2e8229c7fbb2c7d4d55a9ceca922f72d" "/opt/rustwide/cargo-home/bin/cargo" "+ff1737bb00913444173658b4e0b274fd79aabf66" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] c5f454d308c34f7f3331df3c7db18f5e57f87ec8472655c2565a3bdc3ad6f0e8 [INFO] running `Command { std: "docker" "start" "-a" "c5f454d308c34f7f3331df3c7db18f5e57f87ec8472655c2565a3bdc3ad6f0e8", kill_on_drop: false }` [INFO] [stderr] warning: /opt/rustwide/workdir/walk/Cargo.toml: no edition set: defaulting to the 2015 edition while the latest is 2021 [INFO] [stderr] warning: /opt/rustwide/workdir/hdfs-cmd/Cargo.toml: no edition set: defaulting to the 2015 edition while the latest is 2021 [INFO] [stderr] warning: /opt/rustwide/workdir/hdfs/Cargo.toml: no edition set: defaulting to the 2015 edition while the latest is 2021 [INFO] [stderr] warning: /opt/rustwide/workdir/fs_test/Cargo.toml: no edition set: defaulting to the 2015 edition while the latest is 2021 [INFO] [stderr] Compiling libc v0.2.164 [INFO] [stderr] Checking memchr v2.7.4 [INFO] [stderr] Compiling proc-macro2 v1.0.92 [INFO] [stderr] Compiling unicode-ident v1.0.14 [INFO] [stderr] Compiling syn v1.0.109 [INFO] [stderr] Compiling unicode-xid v0.2.6 [INFO] [stderr] Checking gimli v0.31.1 [INFO] [stderr] Checking rand_core v0.4.2 [INFO] [stderr] Compiling failure_derive v0.1.8 [INFO] [stderr] Checking cfg-if v1.0.0 [INFO] [stderr] Checking adler2 v2.0.0 [INFO] [stderr] Checking log v0.4.22 [INFO] [stderr] Checking rustc-demangle v0.1.24 [INFO] [stderr] Compiling gcc v0.3.55 [INFO] [stderr] Compiling nix v0.11.1 [INFO] [stderr] Compiling serde v1.0.215 [INFO] [stderr] Checking bitflags v1.3.2 [INFO] [stderr] Checking miniz_oxide v0.8.0 [INFO] [stderr] Checking regex-syntax v0.8.5 [INFO] [stderr] Checking encoding_rs v0.8.35 [INFO] [stderr] Checking void v1.0.2 [INFO] [stderr] Checking cfg-if v0.1.10 [INFO] [stderr] Checking either v1.13.0 [INFO] [stderr] Checking quick-error v1.2.3 [INFO] [stderr] Checking rand_core v0.3.1 [INFO] [stderr] Checking unicode-width v0.1.14 [INFO] [stderr] Compiling serde_json v1.0.133 [INFO] [stderr] Checking humantime v1.3.0 [INFO] [stderr] Checking termcolor v1.4.1 [INFO] [stderr] Checking glob v0.2.11 [INFO] [stderr] Checking ryu v1.0.18 [INFO] [stderr] Checking ansi_term v0.12.1 [INFO] [stderr] Checking itertools v0.7.11 [INFO] [stderr] Checking yaml-rust v0.3.5 [INFO] [stderr] Checking strsim v0.8.0 [INFO] [stderr] Checking itoa v1.0.13 [INFO] [stderr] Checking textwrap v0.11.0 [INFO] [stderr] Checking vec_map v0.8.2 [INFO] [stderr] Checking walk v0.1.0 (/opt/rustwide/workdir/walk) [INFO] [stderr] Checking object v0.36.5 [INFO] [stderr] Checking aho-corasick v1.1.3 [INFO] [stderr] Compiling hdfs v0.1.0 (/opt/rustwide/workdir/hdfs) [INFO] [stderr] Compiling quote v1.0.37 [INFO] [stderr] Compiling syn v2.0.89 [INFO] [stderr] Checking rand v0.5.6 [INFO] [stderr] Checking atty v0.2.14 [INFO] [stderr] Checking dirs v1.0.5 [INFO] [stderr] Checking clap v2.34.0 [INFO] [stderr] Checking regex-automata v0.4.9 [INFO] [stderr] Checking fs_test v0.1.0 (/opt/rustwide/workdir/fs_test) [INFO] [stderr] Checking addr2line v0.24.2 [INFO] [stderr] Checking toml v0.4.10 [INFO] [stderr] Compiling serde_derive v1.0.215 [INFO] [stderr] Compiling synstructure v0.12.6 [INFO] [stderr] Checking regex v1.11.1 [INFO] [stderr] Checking backtrace v0.3.74 [INFO] [stderr] Checking env_logger v0.5.13 [INFO] [stderr] Checking failure v0.1.8 [INFO] [stderr] Checking quick-xml v0.13.3 [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> walk/src/tests.rs:280:40 [INFO] [stdout] | [INFO] [stdout] 280 | let walkbuilder = WalkBuilder::new(fs); [INFO] [stdout] | ---------------- ^^ expected `&_`, found `MockFS<'_>` [INFO] [stdout] | | [INFO] [stdout] | arguments to this function are incorrect [INFO] [stdout] | [INFO] [stdout] = note: expected reference `&_` [INFO] [stdout] found struct `MockFS<'_>` [INFO] [stdout] note: associated function defined here [INFO] [stdout] --> walk/src/walk.rs:48:12 [INFO] [stdout] | [INFO] [stdout] 48 | pub fn new(file_system: &T) -> WalkBuilder { [INFO] [stdout] | ^^^ --------------- [INFO] [stdout] help: consider borrowing here [INFO] [stdout] | [INFO] [stdout] 280 | let walkbuilder = WalkBuilder::new(&fs); [INFO] [stdout] | + [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> walk/src/tests.rs:302:40 [INFO] [stdout] | [INFO] [stdout] 302 | let walkbuilder = WalkBuilder::new(fs); [INFO] [stdout] | ---------------- ^^ expected `&_`, found `MockFS<'_>` [INFO] [stdout] | | [INFO] [stdout] | arguments to this function are incorrect [INFO] [stdout] | [INFO] [stdout] = note: expected reference `&_` [INFO] [stdout] found struct `MockFS<'_>` [INFO] [stdout] note: associated function defined here [INFO] [stdout] --> walk/src/walk.rs:48:12 [INFO] [stdout] | [INFO] [stdout] 48 | pub fn new(file_system: &T) -> WalkBuilder { [INFO] [stdout] | ^^^ --------------- [INFO] [stdout] help: consider borrowing here [INFO] [stdout] | [INFO] [stdout] 302 | let walkbuilder = WalkBuilder::new(&fs); [INFO] [stdout] | + [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> walk/src/tests.rs:325:40 [INFO] [stdout] | [INFO] [stdout] 325 | let walkbuilder = WalkBuilder::new(fs); [INFO] [stdout] | ---------------- ^^ expected `&_`, found `MockFS<'_>` [INFO] [stdout] | | [INFO] [stdout] | arguments to this function are incorrect [INFO] [stdout] | [INFO] [stdout] = note: expected reference `&_` [INFO] [stdout] found struct `MockFS<'_>` [INFO] [stdout] note: associated function defined here [INFO] [stdout] --> walk/src/walk.rs:48:12 [INFO] [stdout] | [INFO] [stdout] 48 | pub fn new(file_system: &T) -> WalkBuilder { [INFO] [stdout] | ^^^ --------------- [INFO] [stdout] help: consider borrowing here [INFO] [stdout] | [INFO] [stdout] 325 | let walkbuilder = WalkBuilder::new(&fs); [INFO] [stdout] | + [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> walk/src/tests.rs:347:40 [INFO] [stdout] | [INFO] [stdout] 347 | let walkbuilder = WalkBuilder::new(fs); [INFO] [stdout] | ---------------- ^^ expected `&_`, found `MockFS<'_>` [INFO] [stdout] | | [INFO] [stdout] | arguments to this function are incorrect [INFO] [stdout] | [INFO] [stdout] = note: expected reference `&_` [INFO] [stdout] found struct `MockFS<'_>` [INFO] [stdout] note: associated function defined here [INFO] [stdout] --> walk/src/walk.rs:48:12 [INFO] [stdout] | [INFO] [stdout] 48 | pub fn new(file_system: &T) -> WalkBuilder { [INFO] [stdout] | ^^^ --------------- [INFO] [stdout] help: consider borrowing here [INFO] [stdout] | [INFO] [stdout] 347 | let walkbuilder = WalkBuilder::new(&fs); [INFO] [stdout] | + [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> walk/src/tests.rs:369:40 [INFO] [stdout] | [INFO] [stdout] 369 | let walkbuilder = WalkBuilder::new(fs); [INFO] [stdout] | ---------------- ^^ expected `&_`, found `MockFS<'_>` [INFO] [stdout] | | [INFO] [stdout] | arguments to this function are incorrect [INFO] [stdout] | [INFO] [stdout] = note: expected reference `&_` [INFO] [stdout] found struct `MockFS<'_>` [INFO] [stdout] note: associated function defined here [INFO] [stdout] --> walk/src/walk.rs:48:12 [INFO] [stdout] | [INFO] [stdout] 48 | pub fn new(file_system: &T) -> WalkBuilder { [INFO] [stdout] | ^^^ --------------- [INFO] [stdout] help: consider borrowing here [INFO] [stdout] | [INFO] [stdout] 369 | let walkbuilder = WalkBuilder::new(&fs); [INFO] [stdout] | + [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> walk/src/tests.rs:391:40 [INFO] [stdout] | [INFO] [stdout] 391 | let walkbuilder = WalkBuilder::new(fs); [INFO] [stdout] | ---------------- ^^ expected `&_`, found `MockFS<'_>` [INFO] [stdout] | | [INFO] [stdout] | arguments to this function are incorrect [INFO] [stdout] | [INFO] [stdout] = note: expected reference `&_` [INFO] [stdout] found struct `MockFS<'_>` [INFO] [stdout] note: associated function defined here [INFO] [stdout] --> walk/src/walk.rs:48:12 [INFO] [stdout] | [INFO] [stdout] 48 | pub fn new(file_system: &T) -> WalkBuilder { [INFO] [stdout] | ^^^ --------------- [INFO] [stdout] help: consider borrowing here [INFO] [stdout] | [INFO] [stdout] 391 | let walkbuilder = WalkBuilder::new(&fs); [INFO] [stdout] | + [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> walk/src/tests.rs:419:40 [INFO] [stdout] | [INFO] [stdout] 419 | let walkbuilder = WalkBuilder::new(fs); [INFO] [stdout] | ---------------- ^^ expected `&_`, found `MockFS<'_>` [INFO] [stdout] | | [INFO] [stdout] | arguments to this function are incorrect [INFO] [stdout] | [INFO] [stdout] = note: expected reference `&_` [INFO] [stdout] found struct `MockFS<'_>` [INFO] [stdout] note: associated function defined here [INFO] [stdout] --> walk/src/walk.rs:48:12 [INFO] [stdout] | [INFO] [stdout] 48 | pub fn new(file_system: &T) -> WalkBuilder { [INFO] [stdout] | ^^^ --------------- [INFO] [stdout] help: consider borrowing here [INFO] [stdout] | [INFO] [stdout] 419 | let walkbuilder = WalkBuilder::new(&fs); [INFO] [stdout] | + [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> walk/src/tests.rs:455:40 [INFO] [stdout] | [INFO] [stdout] 455 | let walkbuilder = WalkBuilder::new(fs); [INFO] [stdout] | ---------------- ^^ expected `&_`, found `MockFS<'_>` [INFO] [stdout] | | [INFO] [stdout] | arguments to this function are incorrect [INFO] [stdout] | [INFO] [stdout] = note: expected reference `&_` [INFO] [stdout] found struct `MockFS<'_>` [INFO] [stdout] note: associated function defined here [INFO] [stdout] --> walk/src/walk.rs:48:12 [INFO] [stdout] | [INFO] [stdout] 48 | pub fn new(file_system: &T) -> WalkBuilder { [INFO] [stdout] | ^^^ --------------- [INFO] [stdout] help: consider borrowing here [INFO] [stdout] | [INFO] [stdout] 455 | let walkbuilder = WalkBuilder::new(&fs); [INFO] [stdout] | + [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> walk/src/tests.rs:501:40 [INFO] [stdout] | [INFO] [stdout] 501 | let walkbuilder = WalkBuilder::new(fs); [INFO] [stdout] | ---------------- ^^ expected `&_`, found `MockFS<'_>` [INFO] [stdout] | | [INFO] [stdout] | arguments to this function are incorrect [INFO] [stdout] | [INFO] [stdout] = note: expected reference `&_` [INFO] [stdout] found struct `MockFS<'_>` [INFO] [stdout] note: associated function defined here [INFO] [stdout] --> walk/src/walk.rs:48:12 [INFO] [stdout] | [INFO] [stdout] 48 | pub fn new(file_system: &T) -> WalkBuilder { [INFO] [stdout] | ^^^ --------------- [INFO] [stdout] help: consider borrowing here [INFO] [stdout] | [INFO] [stdout] 501 | let walkbuilder = WalkBuilder::new(&fs); [INFO] [stdout] | + [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> walk/src/tests.rs:537:40 [INFO] [stdout] | [INFO] [stdout] 537 | let walkbuilder = WalkBuilder::new(fs); [INFO] [stdout] | ---------------- ^^ expected `&_`, found `MockFS<'_>` [INFO] [stdout] | | [INFO] [stdout] | arguments to this function are incorrect [INFO] [stdout] | [INFO] [stdout] = note: expected reference `&_` [INFO] [stdout] found struct `MockFS<'_>` [INFO] [stdout] note: associated function defined here [INFO] [stdout] --> walk/src/walk.rs:48:12 [INFO] [stdout] | [INFO] [stdout] 48 | pub fn new(file_system: &T) -> WalkBuilder { [INFO] [stdout] | ^^^ --------------- [INFO] [stdout] help: consider borrowing here [INFO] [stdout] | [INFO] [stdout] 537 | let walkbuilder = WalkBuilder::new(&fs); [INFO] [stdout] | + [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0515]: cannot return value referencing local variable `root` [INFO] [stdout] --> walk/src/tests.rs:36:9 [INFO] [stdout] | [INFO] [stdout] 36 | / MockFS { [INFO] [stdout] 37 | | current_node: &root, [INFO] [stdout] | | ----- `root` is borrowed here [INFO] [stdout] 38 | | root, [INFO] [stdout] 39 | | } [INFO] [stdout] | |_________^ returns a value referencing data owned by the current function [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0505]: cannot move out of `root` because it is borrowed [INFO] [stdout] --> walk/src/tests.rs:38:13 [INFO] [stdout] | [INFO] [stdout] 33 | impl<'a> Default for MockFS<'a> { [INFO] [stdout] | -- lifetime `'a` defined here [INFO] [stdout] 34 | fn default() -> Self { [INFO] [stdout] 35 | let root = Node::default(); [INFO] [stdout] | ---- binding `root` declared here [INFO] [stdout] 36 | / MockFS { [INFO] [stdout] 37 | | current_node: &root, [INFO] [stdout] | | ----- borrow of `root` occurs here [INFO] [stdout] 38 | | root, [INFO] [stdout] | | ^^^^ move out of `root` occurs here [INFO] [stdout] 39 | | } [INFO] [stdout] | |_________- returning this value requires that `root` is borrowed for `'a` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0515]: cannot return value referencing function parameter `root` [INFO] [stdout] --> walk/src/tests.rs:46:9 [INFO] [stdout] | [INFO] [stdout] 45 | let current_node = MockFS::find_node_impl(&root, current_dir, &root)?; [INFO] [stdout] | ----- `root` is borrowed here [INFO] [stdout] 46 | Ok(MockFS { root, current_node }) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ returns a value referencing data owned by the current function [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0515]: cannot return value referencing function parameter `root` [INFO] [stdout] --> walk/src/tests.rs:46:9 [INFO] [stdout] | [INFO] [stdout] 45 | let current_node = MockFS::find_node_impl(&root, current_dir, &root)?; [INFO] [stdout] | ----- `root` is borrowed here [INFO] [stdout] 46 | Ok(MockFS { root, current_node }) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ returns a value referencing data owned by the current function [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0505]: cannot move out of `root` because it is borrowed [INFO] [stdout] --> walk/src/tests.rs:46:21 [INFO] [stdout] | [INFO] [stdout] 44 | fn new(root: Node, current_dir: &PathBuf) -> Result { [INFO] [stdout] | ---- - let's call the lifetime of this reference `'1` [INFO] [stdout] | | [INFO] [stdout] | binding `root` declared here [INFO] [stdout] 45 | let current_node = MockFS::find_node_impl(&root, current_dir, &root)?; [INFO] [stdout] | ----- borrow of `root` occurs here [INFO] [stdout] 46 | Ok(MockFS { root, current_node }) [INFO] [stdout] | ------------^^^^----------------- [INFO] [stdout] | | | [INFO] [stdout] | | move out of `root` occurs here [INFO] [stdout] | returning this value requires that `root` is borrowed for `'1` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0515]: cannot return value referencing temporary value [INFO] [stdout] --> walk/src/tests.rs:233:5 [INFO] [stdout] | [INFO] [stdout] 233 | MockFS::new(tree.build(&PathBuf::from("/")), &PathBuf::from("/")).unwrap() [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^------------------^^^^^^^^^^ [INFO] [stdout] | | | [INFO] [stdout] | | temporary value created here [INFO] [stdout] | returns a value referencing data owned by the current function [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0308, E0505, E0515. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0308`. [INFO] [stdout] [INFO] [stderr] error: could not compile `walk` (lib test) due to 16 previous errors [INFO] [stderr] warning: build failed, waiting for other jobs to finish... [INFO] running `Command { std: "docker" "inspect" "c5f454d308c34f7f3331df3c7db18f5e57f87ec8472655c2565a3bdc3ad6f0e8", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "c5f454d308c34f7f3331df3c7db18f5e57f87ec8472655c2565a3bdc3ad6f0e8", kill_on_drop: false }` [INFO] [stdout] c5f454d308c34f7f3331df3c7db18f5e57f87ec8472655c2565a3bdc3ad6f0e8