[INFO] cloning repository https://github.com/soufyaneelasly/drawing [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/soufyaneelasly/drawing" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsoufyaneelasly%2Fdrawing", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsoufyaneelasly%2Fdrawing'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] e4a209ffc980784b6a4a5077630b24372f4947ac [INFO] testing soufyaneelasly/drawing against try#dec9417b8611e34e787a3e4c37686b5131f9e5c5 for pr-154210-1 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsoufyaneelasly%2Fdrawing" "/workspace/builds/worker-0-tc2/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-0-tc2/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/soufyaneelasly/drawing [INFO] finished tweaking git repo https://github.com/soufyaneelasly/drawing [INFO] tweaked toml for git repo https://github.com/soufyaneelasly/drawing written to /workspace/builds/worker-0-tc2/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/soufyaneelasly/drawing on toolchain dec9417b8611e34e787a3e4c37686b5131f9e5c5 [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+dec9417b8611e34e787a3e4c37686b5131f9e5c5" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] crate git repo https://github.com/soufyaneelasly/drawing 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" "+dec9417b8611e34e787a3e4c37686b5131f9e5c5" "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:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+dec9417b8611e34e787a3e4c37686b5131f9e5c5" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] c57c3650f84e93c82649eb8351d47004590dc932a19e9bedc3afba028b11e12b [INFO] running `Command { std: "docker" "start" "-a" "c57c3650f84e93c82649eb8351d47004590dc932a19e9bedc3afba028b11e12b", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "c57c3650f84e93c82649eb8351d47004590dc932a19e9bedc3afba028b11e12b", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "c57c3650f84e93c82649eb8351d47004590dc932a19e9bedc3afba028b11e12b", kill_on_drop: false }` [INFO] [stdout] c57c3650f84e93c82649eb8351d47004590dc932a19e9bedc3afba028b11e12b [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:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+dec9417b8611e34e787a3e4c37686b5131f9e5c5" "build" "--frozen" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 83ce2d66c355948916ed3836545c6e702de7c7718f43f1a5d585af7c4f40512c [INFO] running `Command { std: "docker" "start" "-a" "83ce2d66c355948916ed3836545c6e702de7c7718f43f1a5d585af7c4f40512c", kill_on_drop: false }` [INFO] [stderr] Compiling num-traits v0.2.19 [INFO] [stderr] Compiling num-bigint v0.1.45 [INFO] [stderr] Compiling num-rational v0.1.43 [INFO] [stderr] Compiling rustc-serialize v0.3.25 [INFO] [stderr] Compiling inflate v0.1.1 [INFO] [stderr] Compiling lzw v0.10.0 [INFO] [stderr] Compiling bitflags v0.7.0 [INFO] [stderr] Compiling cc v1.2.30 [INFO] [stderr] Compiling byteorder v0.5.3 [INFO] [stderr] Compiling glob v0.2.11 [INFO] [stderr] Compiling rand v0.4.6 [INFO] [stderr] Compiling getrandom v0.2.16 [INFO] [stderr] Compiling rayon-core v1.12.1 [INFO] [stderr] Compiling gif v0.9.2 [INFO] [stderr] Compiling rand_core v0.6.4 [INFO] [stderr] Compiling rand_chacha v0.3.1 [INFO] [stderr] Compiling rand v0.8.5 [INFO] [stderr] Compiling rayon v1.10.0 [INFO] [stderr] Compiling num-integer v0.1.46 [INFO] [stderr] Compiling num-traits v0.1.43 [INFO] [stderr] Compiling enum_primitive v0.1.1 [INFO] [stderr] Compiling miniz-sys v0.1.12 [INFO] [stderr] Compiling num-iter v0.1.45 [INFO] [stderr] Compiling flate2 v0.2.20 [INFO] [stderr] Compiling png v0.5.2 [INFO] [stderr] Compiling jpeg-decoder v0.1.22 [INFO] [stderr] Compiling image v0.10.4 [INFO] [stderr] Compiling raster v0.2.0 [INFO] [stderr] Compiling geometrical_shapes v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] error: expected `;`, found keyword `use` [INFO] [stdout] --> src/geometrical_shapes.rs:2:14 [INFO] [stdout] | [INFO] [stdout] 2 | use rand::Rng [INFO] [stdout] | ^ help: add `;` here [INFO] [stdout] 3 | use std::f64::{self, consts}; [INFO] [stdout] | --- unexpected token [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `consts` and `self` [INFO] [stdout] --> src/geometrical_shapes.rs:3:16 [INFO] [stdout] | [INFO] [stdout] 3 | use std::f64::{self, consts}; [INFO] [stdout] | ^^^^ ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: arguments to this function are incorrect [INFO] [stdout] --> src/main.rs:10:5 [INFO] [stdout] | [INFO] [stdout] 10 | gs::Line::random(image.width, image.height).draw(&mut image); [INFO] [stdout] | ^^^^^^^^^^^^^^^^ ----------- ------------ expected `&Point`, found `i32` [INFO] [stdout] | | [INFO] [stdout] | expected `&Point`, found `i32` [INFO] [stdout] | [INFO] [stdout] note: associated function defined here [INFO] [stdout] --> src/geometrical_shapes.rs:55:16 [INFO] [stdout] | [INFO] [stdout] 55 | pub fn random(p1: &'a Point, p2: &'a Point) -> Self { [INFO] [stdout] | ^^^^^^ ------------- ------------- [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0624]: associated function `new` is private [INFO] [stdout] --> src/main.rs:14:36 [INFO] [stdout] | [INFO] [stdout] 14 | let rectangle = gs::Rectangle::new(&gs::Point::new(150, 150), &gs::Point::new(50, 50)); [INFO] [stdout] | ^^^ private associated function [INFO] [stdout] | [INFO] [stdout] ::: src/geometrical_shapes.rs:73:5 [INFO] [stdout] | [INFO] [stdout] 73 | fn new(top_left: &'a Point, bottom_right: &'a Point) -> Self { [INFO] [stdout] | ------------------------------------------------------------ private associated function defined here [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0624]: associated function `new` is private [INFO] [stdout] --> src/main.rs:17:34 [INFO] [stdout] | [INFO] [stdout] 17 | let triangle = gs::Triangle::new ( [INFO] [stdout] | ^^^ private associated function [INFO] [stdout] | [INFO] [stdout] ::: src/geometrical_shapes.rs:39:6 [INFO] [stdout] | [INFO] [stdout] 39 | fn new(p1: &'a Point, p2: &'a Point, p3: &'a Point) -> Self { [INFO] [stdout] | ----------------------------------------------------------- private associated function defined here [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0061]: this function takes 1 argument but 2 arguments were supplied [INFO] [stdout] --> src/main.rs:25:9 [INFO] [stdout] | [INFO] [stdout] 25 | gs::Circle::random(image.width, image.height).draw(&mut image); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ ----------- ------------ unexpected argument #2 of type `i32` [INFO] [stdout] | | [INFO] [stdout] | expected `&Point`, found `i32` [INFO] [stdout] | [INFO] [stdout] note: associated function defined here [INFO] [stdout] --> src/geometrical_shapes.rs:91:12 [INFO] [stdout] | [INFO] [stdout] 91 | pub fn random(center: &'a Point) -> Self { [INFO] [stdout] | ^^^^^^ ----------------- [INFO] [stdout] help: remove the extra argument [INFO] [stdout] | [INFO] [stdout] 25 - gs::Circle::random(image.width, image.height).draw(&mut image); [INFO] [stdout] 25 + gs::Circle::random(/* &Point */).draw(&mut image); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `color` [INFO] [stdout] --> src/geometrical_shapes.rs:134:13 [INFO] [stdout] | [INFO] [stdout] 134 | let color = self.color(); [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_color` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0382]: use of moved value: `color` [INFO] [stdout] --> src/geometrical_shapes.rs:189:33 [INFO] [stdout] | [INFO] [stdout] 175 | let color = self.color(); [INFO] [stdout] | ----- move occurs because `color` has type `Color`, which does not implement the `Copy` trait [INFO] [stdout] ... [INFO] [stdout] 188 | loop { [INFO] [stdout] | ---- inside of this loop [INFO] [stdout] 189 | image.display(x, y, color); [INFO] [stdout] | ^^^^^ value moved here, in previous iteration of loop [INFO] [stdout] | [INFO] [stdout] note: consider changing this parameter type in method `display` to borrow instead if owning the value isn't necessary [INFO] [stdout] --> src/geometrical_shapes.rs:113:50 [INFO] [stdout] | [INFO] [stdout] 113 | fn display(&mut self, x: i32, y: i32, color: Color); [INFO] [stdout] | ------- in this method ^^^^^ this parameter takes ownership of the value [INFO] [stdout] help: consider moving the expression out of the loop so it is only moved once [INFO] [stdout] | [INFO] [stdout] 188 ~ let mut value = image.display(x, y, color); [INFO] [stdout] 189 ~ loop { [INFO] [stdout] 190 ~ value; [INFO] [stdout] | [INFO] [stdout] help: consider cloning the value if the performance cost is acceptable [INFO] [stdout] | [INFO] [stdout] 189 | image.display(x, y, color.clone()); [INFO] [stdout] | ++++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0382]: use of moved value: `color` [INFO] [stdout] --> src/geometrical_shapes.rs:225:56 [INFO] [stdout] | [INFO] [stdout] 218 | let color = self.color(); [INFO] [stdout] | ----- move occurs because `color` has type `Color`, which does not implement the `Copy` trait [INFO] [stdout] ... [INFO] [stdout] 224 | while x >= y { [INFO] [stdout] | ------------ inside of this loop [INFO] [stdout] 225 | image.display(center_x + x, center_y + y, color); [INFO] [stdout] | ^^^^^ value used here after move [INFO] [stdout] ... [INFO] [stdout] 232 | image.display(center_x + x, center_y - y, color); [INFO] [stdout] | ----- value moved here, in previous iteration of loop [INFO] [stdout] | [INFO] [stdout] note: consider changing this parameter type in method `display` to borrow instead if owning the value isn't necessary [INFO] [stdout] --> src/geometrical_shapes.rs:113:50 [INFO] [stdout] | [INFO] [stdout] 113 | fn display(&mut self, x: i32, y: i32, color: Color); [INFO] [stdout] | ------- in this method ^^^^^ this parameter takes ownership of the value [INFO] [stdout] help: consider moving the expression out of the loop so it is only moved once [INFO] [stdout] | [INFO] [stdout] 224 ~ let mut value = image.display(center_x + x, center_y - y, color); [INFO] [stdout] 225 ~ while x >= y { [INFO] [stdout] 226 | image.display(center_x + x, center_y + y, color); [INFO] [stdout] ... [INFO] [stdout] 232 | image.display(center_x + y, center_y - x, color); [INFO] [stdout] 233 ~ value; [INFO] [stdout] | [INFO] [stdout] help: consider cloning the value if the performance cost is acceptable [INFO] [stdout] | [INFO] [stdout] 232 | image.display(center_x + x, center_y - y, color.clone()); [INFO] [stdout] | ++++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0382]: use of moved value: `color` [INFO] [stdout] --> src/geometrical_shapes.rs:226:55 [INFO] [stdout] | [INFO] [stdout] 218 | let color = self.color(); [INFO] [stdout] | ----- move occurs because `color` has type `Color`, which does not implement the `Copy` trait [INFO] [stdout] ... [INFO] [stdout] 224 | while x >= y { [INFO] [stdout] | ------------ inside of this loop [INFO] [stdout] 225 | image.display(center_x + x, center_y + y, color); [INFO] [stdout] | ----- value moved here [INFO] [stdout] 226 | image.display(center_x + y, center_y + x, color); [INFO] [stdout] | ^^^^^ value used here after move [INFO] [stdout] | [INFO] [stdout] note: consider changing this parameter type in method `display` to borrow instead if owning the value isn't necessary [INFO] [stdout] --> src/geometrical_shapes.rs:113:50 [INFO] [stdout] | [INFO] [stdout] 113 | fn display(&mut self, x: i32, y: i32, color: Color); [INFO] [stdout] | ------- in this method ^^^^^ this parameter takes ownership of the value [INFO] [stdout] help: consider moving the expression out of the loop so it is only moved once [INFO] [stdout] | [INFO] [stdout] 224 ~ let mut value = image.display(center_x + x, center_y + y, color); [INFO] [stdout] 225 ~ while x >= y { [INFO] [stdout] 226 ~ value; [INFO] [stdout] | [INFO] [stdout] help: consider cloning the value if the performance cost is acceptable [INFO] [stdout] | [INFO] [stdout] 225 | image.display(center_x + x, center_y + y, color.clone()); [INFO] [stdout] | ++++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0382]: use of moved value: `color` [INFO] [stdout] --> src/geometrical_shapes.rs:227:55 [INFO] [stdout] | [INFO] [stdout] 218 | let color = self.color(); [INFO] [stdout] | ----- move occurs because `color` has type `Color`, which does not implement the `Copy` trait [INFO] [stdout] ... [INFO] [stdout] 224 | while x >= y { [INFO] [stdout] | ------------ inside of this loop [INFO] [stdout] 225 | image.display(center_x + x, center_y + y, color); [INFO] [stdout] 226 | image.display(center_x + y, center_y + x, color); [INFO] [stdout] | ----- value moved here [INFO] [stdout] 227 | image.display(center_x - y, center_y + x, color); [INFO] [stdout] | ^^^^^ value used here after move [INFO] [stdout] | [INFO] [stdout] note: consider changing this parameter type in method `display` to borrow instead if owning the value isn't necessary [INFO] [stdout] --> src/geometrical_shapes.rs:113:50 [INFO] [stdout] | [INFO] [stdout] 113 | fn display(&mut self, x: i32, y: i32, color: Color); [INFO] [stdout] | ------- in this method ^^^^^ this parameter takes ownership of the value [INFO] [stdout] help: consider moving the expression out of the loop so it is only moved once [INFO] [stdout] | [INFO] [stdout] 224 ~ let mut value = image.display(center_x + y, center_y + x, color); [INFO] [stdout] 225 ~ while x >= y { [INFO] [stdout] 226 | image.display(center_x + x, center_y + y, color); [INFO] [stdout] 227 ~ value; [INFO] [stdout] | [INFO] [stdout] help: consider cloning the value if the performance cost is acceptable [INFO] [stdout] | [INFO] [stdout] 226 | image.display(center_x + y, center_y + x, color.clone()); [INFO] [stdout] | ++++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0382]: use of moved value: `color` [INFO] [stdout] --> src/geometrical_shapes.rs:228:55 [INFO] [stdout] | [INFO] [stdout] 218 | let color = self.color(); [INFO] [stdout] | ----- move occurs because `color` has type `Color`, which does not implement the `Copy` trait [INFO] [stdout] ... [INFO] [stdout] 224 | while x >= y { [INFO] [stdout] | ------------ inside of this loop [INFO] [stdout] ... [INFO] [stdout] 227 | image.display(center_x - y, center_y + x, color); [INFO] [stdout] | ----- value moved here [INFO] [stdout] 228 | image.display(center_x - x, center_y + y, color); [INFO] [stdout] | ^^^^^ value used here after move [INFO] [stdout] | [INFO] [stdout] note: consider changing this parameter type in method `display` to borrow instead if owning the value isn't necessary [INFO] [stdout] --> src/geometrical_shapes.rs:113:50 [INFO] [stdout] | [INFO] [stdout] 113 | fn display(&mut self, x: i32, y: i32, color: Color); [INFO] [stdout] | ------- in this method ^^^^^ this parameter takes ownership of the value [INFO] [stdout] help: consider moving the expression out of the loop so it is only moved once [INFO] [stdout] | [INFO] [stdout] 224 ~ let mut value = image.display(center_x - y, center_y + x, color); [INFO] [stdout] 225 ~ while x >= y { [INFO] [stdout] 226 | image.display(center_x + x, center_y + y, color); [INFO] [stdout] 227 | image.display(center_x + y, center_y + x, color); [INFO] [stdout] 228 ~ value; [INFO] [stdout] | [INFO] [stdout] help: consider cloning the value if the performance cost is acceptable [INFO] [stdout] | [INFO] [stdout] 227 | image.display(center_x - y, center_y + x, color.clone()); [INFO] [stdout] | ++++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0382]: use of moved value: `color` [INFO] [stdout] --> src/geometrical_shapes.rs:229:55 [INFO] [stdout] | [INFO] [stdout] 218 | let color = self.color(); [INFO] [stdout] | ----- move occurs because `color` has type `Color`, which does not implement the `Copy` trait [INFO] [stdout] ... [INFO] [stdout] 224 | while x >= y { [INFO] [stdout] | ------------ inside of this loop [INFO] [stdout] ... [INFO] [stdout] 228 | image.display(center_x - x, center_y + y, color); [INFO] [stdout] | ----- value moved here [INFO] [stdout] 229 | image.display(center_x - x, center_y - y, color); [INFO] [stdout] | ^^^^^ value used here after move [INFO] [stdout] | [INFO] [stdout] note: consider changing this parameter type in method `display` to borrow instead if owning the value isn't necessary [INFO] [stdout] --> src/geometrical_shapes.rs:113:50 [INFO] [stdout] | [INFO] [stdout] 113 | fn display(&mut self, x: i32, y: i32, color: Color); [INFO] [stdout] | ------- in this method ^^^^^ this parameter takes ownership of the value [INFO] [stdout] help: consider moving the expression out of the loop so it is only moved once [INFO] [stdout] | [INFO] [stdout] 224 ~ let mut value = image.display(center_x - x, center_y + y, color); [INFO] [stdout] 225 ~ while x >= y { [INFO] [stdout] 226 | image.display(center_x + x, center_y + y, color); [INFO] [stdout] 227 | image.display(center_x + y, center_y + x, color); [INFO] [stdout] 228 | image.display(center_x - y, center_y + x, color); [INFO] [stdout] 229 ~ value; [INFO] [stdout] | [INFO] [stdout] help: consider cloning the value if the performance cost is acceptable [INFO] [stdout] | [INFO] [stdout] 228 | image.display(center_x - x, center_y + y, color.clone()); [INFO] [stdout] | ++++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0382]: use of moved value: `color` [INFO] [stdout] --> src/geometrical_shapes.rs:230:55 [INFO] [stdout] | [INFO] [stdout] 218 | let color = self.color(); [INFO] [stdout] | ----- move occurs because `color` has type `Color`, which does not implement the `Copy` trait [INFO] [stdout] ... [INFO] [stdout] 224 | while x >= y { [INFO] [stdout] | ------------ inside of this loop [INFO] [stdout] ... [INFO] [stdout] 229 | image.display(center_x - x, center_y - y, color); [INFO] [stdout] | ----- value moved here [INFO] [stdout] 230 | image.display(center_x - y, center_y - x, color); [INFO] [stdout] | ^^^^^ value used here after move [INFO] [stdout] | [INFO] [stdout] note: consider changing this parameter type in method `display` to borrow instead if owning the value isn't necessary [INFO] [stdout] --> src/geometrical_shapes.rs:113:50 [INFO] [stdout] | [INFO] [stdout] 113 | fn display(&mut self, x: i32, y: i32, color: Color); [INFO] [stdout] | ------- in this method ^^^^^ this parameter takes ownership of the value [INFO] [stdout] help: consider moving the expression out of the loop so it is only moved once [INFO] [stdout] | [INFO] [stdout] 224 ~ let mut value = image.display(center_x - x, center_y - y, color); [INFO] [stdout] 225 ~ while x >= y { [INFO] [stdout] 226 | image.display(center_x + x, center_y + y, color); [INFO] [stdout] ... [INFO] [stdout] 229 | image.display(center_x - x, center_y + y, color); [INFO] [stdout] 230 ~ value; [INFO] [stdout] | [INFO] [stdout] help: consider cloning the value if the performance cost is acceptable [INFO] [stdout] | [INFO] [stdout] 229 | image.display(center_x - x, center_y - y, color.clone()); [INFO] [stdout] | ++++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0382]: use of moved value: `color` [INFO] [stdout] --> src/geometrical_shapes.rs:231:55 [INFO] [stdout] | [INFO] [stdout] 218 | let color = self.color(); [INFO] [stdout] | ----- move occurs because `color` has type `Color`, which does not implement the `Copy` trait [INFO] [stdout] ... [INFO] [stdout] 224 | while x >= y { [INFO] [stdout] | ------------ inside of this loop [INFO] [stdout] ... [INFO] [stdout] 230 | image.display(center_x - y, center_y - x, color); [INFO] [stdout] | ----- value moved here [INFO] [stdout] 231 | image.display(center_x + y, center_y - x, color); [INFO] [stdout] | ^^^^^ value used here after move [INFO] [stdout] | [INFO] [stdout] note: consider changing this parameter type in method `display` to borrow instead if owning the value isn't necessary [INFO] [stdout] --> src/geometrical_shapes.rs:113:50 [INFO] [stdout] | [INFO] [stdout] 113 | fn display(&mut self, x: i32, y: i32, color: Color); [INFO] [stdout] | ------- in this method ^^^^^ this parameter takes ownership of the value [INFO] [stdout] help: consider moving the expression out of the loop so it is only moved once [INFO] [stdout] | [INFO] [stdout] 224 ~ let mut value = image.display(center_x - y, center_y - x, color); [INFO] [stdout] 225 ~ while x >= y { [INFO] [stdout] 226 | image.display(center_x + x, center_y + y, color); [INFO] [stdout] ... [INFO] [stdout] 230 | image.display(center_x - x, center_y - y, color); [INFO] [stdout] 231 ~ value; [INFO] [stdout] | [INFO] [stdout] help: consider cloning the value if the performance cost is acceptable [INFO] [stdout] | [INFO] [stdout] 230 | image.display(center_x - y, center_y - x, color.clone()); [INFO] [stdout] | ++++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0382]: use of moved value: `color` [INFO] [stdout] --> src/geometrical_shapes.rs:232:55 [INFO] [stdout] | [INFO] [stdout] 218 | let color = self.color(); [INFO] [stdout] | ----- move occurs because `color` has type `Color`, which does not implement the `Copy` trait [INFO] [stdout] ... [INFO] [stdout] 224 | while x >= y { [INFO] [stdout] | ------------ inside of this loop [INFO] [stdout] ... [INFO] [stdout] 231 | image.display(center_x + y, center_y - x, color); [INFO] [stdout] | ----- value moved here [INFO] [stdout] 232 | image.display(center_x + x, center_y - y, color); [INFO] [stdout] | ^^^^^ value used here after move [INFO] [stdout] | [INFO] [stdout] note: consider changing this parameter type in method `display` to borrow instead if owning the value isn't necessary [INFO] [stdout] --> src/geometrical_shapes.rs:113:50 [INFO] [stdout] | [INFO] [stdout] 113 | fn display(&mut self, x: i32, y: i32, color: Color); [INFO] [stdout] | ------- in this method ^^^^^ this parameter takes ownership of the value [INFO] [stdout] help: consider moving the expression out of the loop so it is only moved once [INFO] [stdout] | [INFO] [stdout] 224 ~ let mut value = image.display(center_x + y, center_y - x, color); [INFO] [stdout] 225 ~ while x >= y { [INFO] [stdout] 226 | image.display(center_x + x, center_y + y, color); [INFO] [stdout] ... [INFO] [stdout] 231 | image.display(center_x - y, center_y - x, color); [INFO] [stdout] 232 ~ value; [INFO] [stdout] | [INFO] [stdout] help: consider cloning the value if the performance cost is acceptable [INFO] [stdout] | [INFO] [stdout] 231 | image.display(center_x + y, center_y - x, color.clone()); [INFO] [stdout] | ++++++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0061, E0308, E0382, E0624. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0061`. [INFO] [stdout] [INFO] [stderr] error: could not compile `geometrical_shapes` (bin "geometrical_shapes") due to 14 previous errors; 2 warnings emitted [INFO] running `Command { std: "docker" "inspect" "83ce2d66c355948916ed3836545c6e702de7c7718f43f1a5d585af7c4f40512c", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "83ce2d66c355948916ed3836545c6e702de7c7718f43f1a5d585af7c4f40512c", kill_on_drop: false }` [INFO] [stdout] 83ce2d66c355948916ed3836545c6e702de7c7718f43f1a5d585af7c4f40512c