[INFO] cloning repository https://github.com/qwertydelle/Snake [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/qwertydelle/Snake" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fqwertydelle%2FSnake", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fqwertydelle%2FSnake'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] cf8f98597e465735080ba16a58d621f2f6d3271b [INFO] testing qwertydelle/Snake against try#1b74e096b9bfb06f84a3007193dcd2f059cbdf6a for pr-96025 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fqwertydelle%2FSnake" "/workspace/builds/worker-14/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-14/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/qwertydelle/Snake on toolchain 1b74e096b9bfb06f84a3007193dcd2f059cbdf6a [INFO] running `Command { std: "/workspace/cargo-home/bin/cargo" "+1b74e096b9bfb06f84a3007193dcd2f059cbdf6a" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/qwertydelle/Snake [INFO] finished tweaking git repo https://github.com/qwertydelle/Snake [INFO] tweaked toml for git repo https://github.com/qwertydelle/Snake written to /workspace/builds/worker-14/source/Cargo.toml [INFO] crate git repo https://github.com/qwertydelle/Snake already has a lockfile, it will not be regenerated [INFO] running `Command { std: "/workspace/cargo-home/bin/cargo" "+1b74e096b9bfb06f84a3007193dcd2f059cbdf6a" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-14/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-14/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:b0c94ce3c1162fcb8e57cac5b65ec2f72eabb1eebea4fcc35e269e823f681646" "/opt/rustwide/cargo-home/bin/cargo" "+1b74e096b9bfb06f84a3007193dcd2f059cbdf6a" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] f5894441dde9932d29c94cc8e93d37a84bf0bf95b02980173141afe94b0d5ffb [INFO] [stderr] WARNING: Your kernel does not support swap limit capabilities or the cgroup is not mounted. Memory limited without swap. [INFO] running `Command { std: "docker" "start" "-a" "f5894441dde9932d29c94cc8e93d37a84bf0bf95b02980173141afe94b0d5ffb", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "f5894441dde9932d29c94cc8e93d37a84bf0bf95b02980173141afe94b0d5ffb", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "f5894441dde9932d29c94cc8e93d37a84bf0bf95b02980173141afe94b0d5ffb", kill_on_drop: false }` [INFO] [stdout] f5894441dde9932d29c94cc8e93d37a84bf0bf95b02980173141afe94b0d5ffb [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-14/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-14/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" "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:b0c94ce3c1162fcb8e57cac5b65ec2f72eabb1eebea4fcc35e269e823f681646" "/opt/rustwide/cargo-home/bin/cargo" "+1b74e096b9bfb06f84a3007193dcd2f059cbdf6a" "build" "--frozen" "--message-format=json", kill_on_drop: false }` [INFO] [stderr] WARNING: Your kernel does not support swap limit capabilities or the cgroup is not mounted. Memory limited without swap. [INFO] [stdout] 44669d88a616c9673b866780ec509d155736344e699f24c24e66a5dd23817c86 [INFO] running `Command { std: "docker" "start" "-a" "44669d88a616c9673b866780ec509d155736344e699f24c24e66a5dd23817c86", kill_on_drop: false }` [INFO] [stderr] Compiling cfg-if v1.0.0 [INFO] [stderr] Compiling libc v0.2.116 [INFO] [stderr] Compiling autocfg v1.0.1 [INFO] [stderr] Compiling proc-macro2 v1.0.36 [INFO] [stderr] Compiling pkg-config v0.3.24 [INFO] [stderr] Compiling unicode-xid v0.2.2 [INFO] [stderr] Compiling bitflags v1.3.2 [INFO] [stderr] Compiling lazy_static v1.4.0 [INFO] [stderr] Compiling log v0.4.14 [INFO] [stderr] Compiling xml-rs v0.8.4 [INFO] [stderr] Compiling version_check v0.9.4 [INFO] [stderr] Compiling syn v1.0.86 [INFO] [stderr] Compiling khronos_api v3.1.0 [INFO] [stderr] Compiling scopeguard v1.1.0 [INFO] [stderr] Compiling crossbeam-utils v0.8.6 [INFO] [stderr] Compiling smallvec v1.8.0 [INFO] [stderr] Compiling crossbeam-epoch v0.9.6 [INFO] [stderr] Compiling ab_glyph_rasterizer v0.1.5 [INFO] [stderr] Compiling serde_derive v1.0.136 [INFO] [stderr] Compiling cc v1.0.72 [INFO] [stderr] Compiling serde v1.0.136 [INFO] [stderr] Compiling memchr v2.4.1 [INFO] [stderr] Compiling same-file v1.0.6 [INFO] [stderr] Compiling once_cell v1.9.0 [INFO] [stderr] Compiling parking_lot_core v0.8.5 [INFO] [stderr] Compiling downcast-rs v1.2.0 [INFO] [stderr] Compiling scoped-tls v1.0.0 [INFO] [stderr] Compiling minimal-lexical v0.2.1 [INFO] [stderr] Compiling nix v0.18.0 [INFO] [stderr] Compiling crossbeam-queue v0.3.3 [INFO] [stderr] Compiling byteorder v1.4.3 [INFO] [stderr] Compiling ttf-parser v0.6.2 [INFO] [stderr] Compiling ucd-trie v0.1.3 [INFO] [stderr] Compiling rayon-core v1.9.1 [INFO] [stderr] Compiling serde_json v1.0.78 [INFO] [stderr] Compiling cfg-if v0.1.10 [INFO] [stderr] Compiling crc32fast v1.3.1 [INFO] [stderr] Compiling cty v0.2.2 [INFO] [stderr] Compiling ryu v1.0.9 [INFO] [stderr] Compiling itoa v1.0.1 [INFO] [stderr] Compiling arrayvec v0.5.2 [INFO] [stderr] Compiling ttf-parser v0.14.0 [INFO] [stderr] Compiling pulldown-cmark v0.8.0 [INFO] [stderr] Compiling remove_dir_all v0.5.3 [INFO] [stderr] Compiling adler32 v1.2.0 [INFO] [stderr] Compiling ppv-lite86 v0.2.16 [INFO] [stderr] Compiling winit v0.25.0 [INFO] [stderr] Compiling fastrand v1.7.0 [INFO] [stderr] Compiling tinyvec_macros v0.1.0 [INFO] [stderr] Compiling percent-encoding v2.1.0 [INFO] [stderr] Compiling glob v0.3.0 [INFO] [stderr] Compiling cpal v0.13.5 [INFO] [stderr] Compiling either v1.6.1 [INFO] [stderr] Compiling adler v1.0.2 [INFO] [stderr] Compiling weezl v0.1.5 [INFO] [stderr] Compiling bytecount v0.6.2 [INFO] [stderr] Compiling uuid v0.8.2 [INFO] [stderr] Compiling jpeg-decoder v0.1.22 [INFO] [stderr] Compiling linked-hash-map v0.5.4 [INFO] [stderr] Compiling static_assertions v1.1.0 [INFO] [stderr] Compiling xi-unicode v0.3.0 [INFO] [stderr] Compiling rustc-hash v1.1.0 [INFO] [stderr] Compiling vec_map v0.8.2 [INFO] [stderr] Compiling fnv v1.0.7 [INFO] [stderr] Compiling color_quant v1.1.0 [INFO] [stderr] Compiling mint v0.5.8 [INFO] [stderr] Compiling hound v3.4.0 [INFO] [stderr] Compiling claxon v0.4.3 [INFO] [stderr] Compiling bytemuck v1.7.3 [INFO] [stderr] Compiling libloading v0.7.3 [INFO] [stderr] Compiling instant v0.1.12 [INFO] [stderr] Compiling libloading v0.6.7 [INFO] [stderr] Compiling draw_state v0.8.0 [INFO] [stderr] Compiling lock_api v0.4.6 [INFO] [stderr] Compiling walkdir v2.3.2 [INFO] [stderr] Compiling pest v2.1.3 [INFO] [stderr] Compiling raw-window-handle v0.4.2 [INFO] [stderr] Compiling nom v7.1.0 [INFO] [stderr] Compiling unicase v2.6.0 [INFO] [stderr] Compiling error-chain v0.12.4 [INFO] [stderr] Compiling memoffset v0.6.5 [INFO] [stderr] Compiling num-traits v0.2.14 [INFO] [stderr] Compiling num-integer v0.1.44 [INFO] [stderr] Compiling miniz_oxide v0.4.4 [INFO] [stderr] Compiling rayon v1.5.1 [INFO] [stderr] Compiling num-iter v0.1.42 [INFO] [stderr] Compiling num-rational v0.3.2 [INFO] [stderr] Compiling ogg v0.8.0 [INFO] [stderr] Compiling miniz_oxide v0.3.7 [INFO] [stderr] Compiling deflate v0.8.6 [INFO] [stderr] Compiling tinyvec v1.5.1 [INFO] [stderr] Compiling wayland-sys v0.28.6 [INFO] [stderr] Compiling x11-dl v2.19.1 [INFO] [stderr] Compiling alsa-sys v0.3.1 [INFO] [stderr] Compiling libudev-sys v0.1.4 [INFO] [stderr] Compiling collider v0.3.1 [INFO] [stderr] Compiling gif v0.11.3 [INFO] [stderr] Compiling dlib v0.5.0 [INFO] [stderr] Compiling dlib v0.4.2 [INFO] [stderr] Compiling glam v0.20.2 [INFO] [stderr] Compiling owned_ttf_parser v0.6.0 [INFO] [stderr] Compiling gfx_core v0.9.2 [INFO] [stderr] Compiling gl_generator v0.14.0 [INFO] [stderr] Compiling minimp3-sys v0.3.2 [INFO] [stderr] Compiling bzip2-sys v0.1.11+1.0.8 [INFO] [stderr] Compiling crossbeam-channel v0.5.2 [INFO] [stderr] Compiling owned_ttf_parser v0.14.0 [INFO] [stderr] Compiling semver-parser v0.10.2 [INFO] [stderr] Compiling rusttype v0.9.2 [INFO] [stderr] Compiling quote v1.0.15 [INFO] [stderr] Compiling png v0.16.8 [INFO] [stderr] Compiling lewton v0.10.2 [INFO] [stderr] Compiling ab_glyph v0.2.13 [INFO] [stderr] Compiling wayland-scanner v0.28.6 [INFO] [stderr] Compiling tempfile v3.3.0 [INFO] [stderr] Compiling tiff v0.6.1 [INFO] [stderr] Compiling nix v0.20.0 [INFO] [stderr] Compiling dirs-sys v0.3.6 [INFO] [stderr] Compiling nix v0.23.1 [INFO] [stderr] Compiling getrandom v0.2.4 [INFO] [stderr] Compiling num_cpus v1.13.1 [INFO] [stderr] Compiling mio v0.7.14 [INFO] [stderr] Compiling memmap2 v0.1.0 [INFO] [stderr] Compiling raw-window-handle v0.3.4 [INFO] [stderr] Compiling shared_library v0.1.9 [INFO] [stderr] Compiling slice-deque v0.3.0 [INFO] [stderr] Compiling euclid v0.22.6 [INFO] [stderr] Compiling sid v0.6.1 [INFO] [stderr] Compiling approx v0.5.1 [INFO] [stderr] Compiling float_next_after v0.1.5 [INFO] [stderr] Compiling ordered-float v2.10.0 [INFO] [stderr] Compiling crossbeam-deque v0.8.1 [INFO] [stderr] Compiling dirs v3.0.2 [INFO] [stderr] Compiling directories v3.0.2 [INFO] [stderr] Compiling gfx v0.18.2 [INFO] [stderr] Compiling glutin_glx_sys v0.1.7 [INFO] [stderr] Compiling gfx_gl v0.6.1 [INFO] [stderr] Compiling glutin_egl_sys v0.1.5 [INFO] [stderr] Compiling parking_lot v0.11.2 [INFO] [stderr] Compiling rand_core v0.6.3 [INFO] [stderr] Compiling osmesa-sys v0.1.2 [INFO] [stderr] Compiling glyph_brush_layout v0.2.3 [INFO] [stderr] Compiling bzip2 v0.4.3 [INFO] [stderr] Compiling xcursor v0.3.4 [INFO] [stderr] Compiling xdg v2.4.0 [INFO] [stderr] Compiling crossbeam v0.8.1 [INFO] [stderr] Compiling wayland-client v0.28.6 [INFO] [stderr] Compiling wayland-protocols v0.28.6 [INFO] [stderr] Compiling rand_chacha v0.3.1 [INFO] [stderr] Compiling lyon_geom v0.17.6 [INFO] [stderr] Compiling mio-misc v1.2.2 [INFO] [stderr] Compiling andrew v0.3.1 [INFO] [stderr] Compiling image v0.23.14 [INFO] [stderr] Compiling rand v0.8.4 [INFO] [stderr] Compiling toml v0.5.8 [INFO] [stderr] Compiling lyon_path v0.17.7 [INFO] [stderr] Compiling wayland-commons v0.28.6 [INFO] [stderr] Compiling twox-hash v1.6.2 [INFO] [stderr] Compiling calloop v0.6.5 [INFO] [stderr] Compiling lyon_algorithms v0.17.7 [INFO] [stderr] Compiling lyon_tessellation v0.17.10 [INFO] [stderr] Compiling alsa v0.6.0 [INFO] [stderr] Compiling gilrs-core v0.3.2 [INFO] [stderr] Compiling lyon v0.17.10 [INFO] [stderr] Compiling gilrs v0.8.2 [INFO] [stderr] Compiling glyph_brush_draw_cache v0.1.5 [INFO] [stderr] Compiling glyph_brush v0.7.3 [INFO] [stderr] Compiling thiserror-impl v1.0.30 [INFO] [stderr] Compiling smart-default v0.6.0 [INFO] [stderr] Compiling wayland-cursor v0.28.6 [INFO] [stderr] Compiling wayland-egl v0.28.6 [INFO] [stderr] Compiling gfx_device_gl v0.16.2 [INFO] [stderr] Compiling thiserror v1.0.30 [INFO] [stderr] Compiling minimp3 v0.5.1 [INFO] [stderr] Compiling zip v0.5.13 [INFO] [stderr] Compiling rodio v0.14.0 [INFO] [stderr] Compiling smithay-client-toolkit v0.12.3 [INFO] [stderr] Compiling semver v0.11.0 [INFO] [stderr] Compiling cargo-platform v0.1.2 [INFO] [stderr] Compiling cargo_metadata v0.12.3 [INFO] [stderr] Compiling glutin v0.27.0 [INFO] [stderr] Compiling skeptic v0.13.6 [INFO] [stderr] Compiling old_school_gfx_glutin_ext v0.27.0 [INFO] [stderr] Compiling ggez v0.7.0 [INFO] [stderr] Compiling snake_game v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/main.rs:198:12 [INFO] [stdout] | [INFO] [stdout] 198 | ...if ((self.apple.pos.0 - 30 < self.snake.parts.front().unwrap().x && self.apple.pos.0 + 30 >= self.snake.parts.front().unwrap().x) && (self.apple.pos.1 - 30 < self.snake.parts.front().unwrap().y && self.apple.pos.1 + 30 >= self.snake.parts.front().unwrap().y)... [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 198 - if ((self.apple.pos.0 - 30 < self.snake.parts.front().unwrap().x && self.apple.pos.0 + 30 >= self.snake.parts.front().unwrap().x) && (self.apple.pos.1 - 30 < self.snake.parts.front().unwrap().y && self.apple.pos.1 + 30 >= self.snake.parts.front().unwrap().y)) { [INFO] [stdout] 198 + if (self.apple.pos.0 - 30 < self.snake.parts.front().unwrap().x && self.apple.pos.0 + 30 >= self.snake.parts.front().unwrap().x) && (self.apple.pos.1 - 30 < self.snake.parts.front().unwrap().y && self.apple.pos.1 + 30 >= self.snake.parts.front().unwrap().y) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/main.rs:206:11 [INFO] [stdout] | [INFO] [stdout] 206 | if(self.snake.parts.front().unwrap().x > window_x as i32) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 206 - if(self.snake.parts.front().unwrap().x > window_x as i32) { [INFO] [stdout] 206 + if self.snake.parts.front().unwrap().x > window_x as i32 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/main.rs:208:17 [INFO] [stdout] | [INFO] [stdout] 208 | }else if(self.snake.parts.front().unwrap().x < 0) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 208 - }else if(self.snake.parts.front().unwrap().x < 0) { [INFO] [stdout] 208 + }else if self.snake.parts.front().unwrap().x < 0 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/main.rs:213:11 [INFO] [stdout] | [INFO] [stdout] 213 | if(self.snake.parts.front().unwrap().y > window_y as i32) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 213 - if(self.snake.parts.front().unwrap().y > window_y as i32) { [INFO] [stdout] 213 + if self.snake.parts.front().unwrap().y > window_y as i32 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/main.rs:215:17 [INFO] [stdout] | [INFO] [stdout] 215 | }else if(self.snake.parts.front().unwrap().y < 0) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 215 - }else if(self.snake.parts.front().unwrap().y < 0) { [INFO] [stdout] 215 + }else if self.snake.parts.front().unwrap().y < 0 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `ctx` [INFO] [stdout] --> src/main.rs:265:33 [INFO] [stdout] | [INFO] [stdout] 265 | fn key_down_event(&mut self,ctx: &mut Context, keycode: KeyCode, keymods: KeyMods, repeat: bool) { [INFO] [stdout] | ^^^ help: if this is intentional, prefix it with an underscore: `_ctx` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `keymods` [INFO] [stdout] --> src/main.rs:265:70 [INFO] [stdout] | [INFO] [stdout] 265 | fn key_down_event(&mut self,ctx: &mut Context, keycode: KeyCode, keymods: KeyMods, repeat: bool) { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_keymods` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `repeat` [INFO] [stdout] --> src/main.rs:265:88 [INFO] [stdout] | [INFO] [stdout] 265 | fn key_down_event(&mut self,ctx: &mut Context, keycode: KeyCode, keymods: KeyMods, repeat: bool) { [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_repeat` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: cannot borrow `self.parts` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/main.rs:76:17 [INFO] [stdout] | [INFO] [stdout] 65 | let head_part: &Part = self.parts.back().unwrap(); [INFO] [stdout] | ----------------- immutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 76 | self.parts.push_back(Part {x: head_part.x, y: head_part.y - 10}); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | | [INFO] [stdout] | | immutable borrow later used here [INFO] [stdout] | mutable borrow occurs here [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(mutable_borrow_reservation_conflict)]` on by default [INFO] [stdout] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stdout] = note: for more information, see issue #59159 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: cannot borrow `self.parts` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/main.rs:70:17 [INFO] [stdout] | [INFO] [stdout] 65 | let head_part: &Part = self.parts.back().unwrap(); [INFO] [stdout] | ----------------- immutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 70 | self.parts.push_back(Part {x: head_part.x - 10, y: head_part.y}); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | | [INFO] [stdout] | | immutable borrow later used here [INFO] [stdout] | mutable borrow occurs here [INFO] [stdout] | [INFO] [stdout] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stdout] = note: for more information, see issue #59159 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: cannot borrow `self.parts` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/main.rs:79:17 [INFO] [stdout] | [INFO] [stdout] 65 | let head_part: &Part = self.parts.back().unwrap(); [INFO] [stdout] | ----------------- immutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 79 | self.parts.push_back(Part {x: head_part.x, y: head_part.y + 10}); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | | [INFO] [stdout] | | immutable borrow later used here [INFO] [stdout] | mutable borrow occurs here [INFO] [stdout] | [INFO] [stdout] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stdout] = note: for more information, see issue #59159 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: cannot borrow `self.parts` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/main.rs:73:17 [INFO] [stdout] | [INFO] [stdout] 65 | let head_part: &Part = self.parts.back().unwrap(); [INFO] [stdout] | ----------------- immutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 73 | self.parts.push_back(Part {x: head_part.x + 10, y: head_part.y}); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | | [INFO] [stdout] | | immutable borrow later used here [INFO] [stdout] | mutable borrow occurs here [INFO] [stdout] | [INFO] [stdout] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stdout] = note: for more information, see issue #59159 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/main.rs:89:13 [INFO] [stdout] | [INFO] [stdout] 89 | let mut head: &mut Part = self.parts.front_mut().unwrap(); [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: associated function is never used: `new_op` [INFO] [stdout] --> src/main.rs:147:8 [INFO] [stdout] | [INFO] [stdout] 147 | fn new_op(r: u8, g: u8, b: u8, size: i32) -> Self { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused `Result` that must be used [INFO] [stdout] --> src/main.rs:255:9 [INFO] [stdout] | [INFO] [stdout] 255 | graphics::draw(ctx, &score, DrawParam::default()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_must_use)]` on by default [INFO] [stdout] = note: this `Result` may be an `Err` variant, which should be handled [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused `Result` that must be used [INFO] [stdout] --> src/main.rs:256:9 [INFO] [stdout] | [INFO] [stdout] 256 | graphics::draw(ctx, &highscore, DrawParam::default().dest(high_rect)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: this `Result` may be an `Err` variant, which should be handled [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 16 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished dev [unoptimized + debuginfo] target(s) in 4m 29s [INFO] running `Command { std: "docker" "inspect" "44669d88a616c9673b866780ec509d155736344e699f24c24e66a5dd23817c86", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "44669d88a616c9673b866780ec509d155736344e699f24c24e66a5dd23817c86", kill_on_drop: false }` [INFO] [stdout] 44669d88a616c9673b866780ec509d155736344e699f24c24e66a5dd23817c86 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-14/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-14/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" "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:b0c94ce3c1162fcb8e57cac5b65ec2f72eabb1eebea4fcc35e269e823f681646" "/opt/rustwide/cargo-home/bin/cargo" "+1b74e096b9bfb06f84a3007193dcd2f059cbdf6a" "test" "--frozen" "--no-run" "--message-format=json", kill_on_drop: false }` [INFO] [stderr] WARNING: Your kernel does not support swap limit capabilities or the cgroup is not mounted. Memory limited without swap. [INFO] [stdout] 8b5c081169ad6cd5f811e2f16cd1dbf8444fba3cd9983b7313a0c0ad70921f0f [INFO] running `Command { std: "docker" "start" "-a" "8b5c081169ad6cd5f811e2f16cd1dbf8444fba3cd9983b7313a0c0ad70921f0f", kill_on_drop: false }` [INFO] [stderr] Compiling snake_game v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/main.rs:198:12 [INFO] [stdout] | [INFO] [stdout] 198 | ...if ((self.apple.pos.0 - 30 < self.snake.parts.front().unwrap().x && self.apple.pos.0 + 30 >= self.snake.parts.front().unwrap().x) && (self.apple.pos.1 - 30 < self.snake.parts.front().unwrap().y && self.apple.pos.1 + 30 >= self.snake.parts.front().unwrap().y)... [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 198 - if ((self.apple.pos.0 - 30 < self.snake.parts.front().unwrap().x && self.apple.pos.0 + 30 >= self.snake.parts.front().unwrap().x) && (self.apple.pos.1 - 30 < self.snake.parts.front().unwrap().y && self.apple.pos.1 + 30 >= self.snake.parts.front().unwrap().y)) { [INFO] [stdout] 198 + if (self.apple.pos.0 - 30 < self.snake.parts.front().unwrap().x && self.apple.pos.0 + 30 >= self.snake.parts.front().unwrap().x) && (self.apple.pos.1 - 30 < self.snake.parts.front().unwrap().y && self.apple.pos.1 + 30 >= self.snake.parts.front().unwrap().y) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/main.rs:206:11 [INFO] [stdout] | [INFO] [stdout] 206 | if(self.snake.parts.front().unwrap().x > window_x as i32) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 206 - if(self.snake.parts.front().unwrap().x > window_x as i32) { [INFO] [stdout] 206 + if self.snake.parts.front().unwrap().x > window_x as i32 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/main.rs:208:17 [INFO] [stdout] | [INFO] [stdout] 208 | }else if(self.snake.parts.front().unwrap().x < 0) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 208 - }else if(self.snake.parts.front().unwrap().x < 0) { [INFO] [stdout] 208 + }else if self.snake.parts.front().unwrap().x < 0 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/main.rs:213:11 [INFO] [stdout] | [INFO] [stdout] 213 | if(self.snake.parts.front().unwrap().y > window_y as i32) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 213 - if(self.snake.parts.front().unwrap().y > window_y as i32) { [INFO] [stdout] 213 + if self.snake.parts.front().unwrap().y > window_y as i32 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/main.rs:215:17 [INFO] [stdout] | [INFO] [stdout] 215 | }else if(self.snake.parts.front().unwrap().y < 0) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 215 - }else if(self.snake.parts.front().unwrap().y < 0) { [INFO] [stdout] 215 + }else if self.snake.parts.front().unwrap().y < 0 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `ctx` [INFO] [stdout] --> src/main.rs:265:33 [INFO] [stdout] | [INFO] [stdout] 265 | fn key_down_event(&mut self,ctx: &mut Context, keycode: KeyCode, keymods: KeyMods, repeat: bool) { [INFO] [stdout] | ^^^ help: if this is intentional, prefix it with an underscore: `_ctx` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `keymods` [INFO] [stdout] --> src/main.rs:265:70 [INFO] [stdout] | [INFO] [stdout] 265 | fn key_down_event(&mut self,ctx: &mut Context, keycode: KeyCode, keymods: KeyMods, repeat: bool) { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_keymods` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `repeat` [INFO] [stdout] --> src/main.rs:265:88 [INFO] [stdout] | [INFO] [stdout] 265 | fn key_down_event(&mut self,ctx: &mut Context, keycode: KeyCode, keymods: KeyMods, repeat: bool) { [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_repeat` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: cannot borrow `self.parts` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/main.rs:76:17 [INFO] [stdout] | [INFO] [stdout] 65 | let head_part: &Part = self.parts.back().unwrap(); [INFO] [stdout] | ----------------- immutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 76 | self.parts.push_back(Part {x: head_part.x, y: head_part.y - 10}); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | | [INFO] [stdout] | | immutable borrow later used here [INFO] [stdout] | mutable borrow occurs here [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(mutable_borrow_reservation_conflict)]` on by default [INFO] [stdout] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stdout] = note: for more information, see issue #59159 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: cannot borrow `self.parts` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/main.rs:70:17 [INFO] [stdout] | [INFO] [stdout] 65 | let head_part: &Part = self.parts.back().unwrap(); [INFO] [stdout] | ----------------- immutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 70 | self.parts.push_back(Part {x: head_part.x - 10, y: head_part.y}); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | | [INFO] [stdout] | | immutable borrow later used here [INFO] [stdout] | mutable borrow occurs here [INFO] [stdout] | [INFO] [stdout] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stdout] = note: for more information, see issue #59159 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: cannot borrow `self.parts` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/main.rs:79:17 [INFO] [stdout] | [INFO] [stdout] 65 | let head_part: &Part = self.parts.back().unwrap(); [INFO] [stdout] | ----------------- immutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 79 | self.parts.push_back(Part {x: head_part.x, y: head_part.y + 10}); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | | [INFO] [stdout] | | immutable borrow later used here [INFO] [stdout] | mutable borrow occurs here [INFO] [stdout] | [INFO] [stdout] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stdout] = note: for more information, see issue #59159 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: cannot borrow `self.parts` as mutable because it is also borrowed as immutable [INFO] [stdout] --> src/main.rs:73:17 [INFO] [stdout] | [INFO] [stdout] 65 | let head_part: &Part = self.parts.back().unwrap(); [INFO] [stdout] | ----------------- immutable borrow occurs here [INFO] [stdout] ... [INFO] [stdout] 73 | self.parts.push_back(Part {x: head_part.x + 10, y: head_part.y}); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | | [INFO] [stdout] | | immutable borrow later used here [INFO] [stdout] | mutable borrow occurs here [INFO] [stdout] | [INFO] [stdout] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stdout] = note: for more information, see issue #59159 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/main.rs:89:13 [INFO] [stdout] | [INFO] [stdout] 89 | let mut head: &mut Part = self.parts.front_mut().unwrap(); [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: associated function is never used: `new_op` [INFO] [stdout] --> src/main.rs:147:8 [INFO] [stdout] | [INFO] [stdout] 147 | fn new_op(r: u8, g: u8, b: u8, size: i32) -> Self { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused `Result` that must be used [INFO] [stdout] --> src/main.rs:255:9 [INFO] [stdout] | [INFO] [stdout] 255 | graphics::draw(ctx, &score, DrawParam::default()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_must_use)]` on by default [INFO] [stdout] = note: this `Result` may be an `Err` variant, which should be handled [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused `Result` that must be used [INFO] [stdout] --> src/main.rs:256:9 [INFO] [stdout] | [INFO] [stdout] 256 | graphics::draw(ctx, &highscore, DrawParam::default().dest(high_rect)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: this `Result` may be an `Err` variant, which should be handled [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 16 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished test [unoptimized + debuginfo] target(s) in 1.67s [INFO] [stderr] Executable unittests src/main.rs (/opt/rustwide/target/debug/deps/snake_game-dba92b6c4895a513) [INFO] running `Command { std: "docker" "inspect" "8b5c081169ad6cd5f811e2f16cd1dbf8444fba3cd9983b7313a0c0ad70921f0f", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "8b5c081169ad6cd5f811e2f16cd1dbf8444fba3cd9983b7313a0c0ad70921f0f", kill_on_drop: false }` [INFO] [stdout] 8b5c081169ad6cd5f811e2f16cd1dbf8444fba3cd9983b7313a0c0ad70921f0f [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-14/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-14/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" "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:b0c94ce3c1162fcb8e57cac5b65ec2f72eabb1eebea4fcc35e269e823f681646" "/opt/rustwide/cargo-home/bin/cargo" "+1b74e096b9bfb06f84a3007193dcd2f059cbdf6a" "test" "--frozen", kill_on_drop: false }` [INFO] [stdout] 0f99b963863d090091ae45820c0ad59123d0879b02734d618b90452e4223788b [INFO] [stderr] WARNING: Your kernel does not support swap limit capabilities or the cgroup is not mounted. Memory limited without swap. [INFO] running `Command { std: "docker" "start" "-a" "0f99b963863d090091ae45820c0ad59123d0879b02734d618b90452e4223788b", kill_on_drop: false }` [INFO] [stderr] warning: unnecessary parentheses around `if` condition [INFO] [stderr] --> src/main.rs:198:12 [INFO] [stderr] | [INFO] [stderr] 198 | ...if ((self.apple.pos.0 - 30 < self.snake.parts.front().unwrap().x && self.apple.pos.0 + 30 >= self.snake.parts.front().unwrap().x) && (self.apple.pos.1 - 30 < self.snake.parts.front().unwrap().y && self.apple.pos.1 + 30 >= self.snake.parts.front().unwrap().y)... [INFO] [stderr] | ^ ^ [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(unused_parens)]` on by default [INFO] [stderr] help: remove these parentheses [INFO] [stderr] | [INFO] [stderr] 198 - if ((self.apple.pos.0 - 30 < self.snake.parts.front().unwrap().x && self.apple.pos.0 + 30 >= self.snake.parts.front().unwrap().x) && (self.apple.pos.1 - 30 < self.snake.parts.front().unwrap().y && self.apple.pos.1 + 30 >= self.snake.parts.front().unwrap().y)) { [INFO] [stderr] 198 + if (self.apple.pos.0 - 30 < self.snake.parts.front().unwrap().x && self.apple.pos.0 + 30 >= self.snake.parts.front().unwrap().x) && (self.apple.pos.1 - 30 < self.snake.parts.front().unwrap().y && self.apple.pos.1 + 30 >= self.snake.parts.front().unwrap().y) { [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: unnecessary parentheses around `if` condition [INFO] [stderr] --> src/main.rs:206:11 [INFO] [stderr] | [INFO] [stderr] 206 | if(self.snake.parts.front().unwrap().x > window_x as i32) { [INFO] [stderr] | ^ ^ [INFO] [stderr] | [INFO] [stderr] help: remove these parentheses [INFO] [stderr] | [INFO] [stderr] 206 - if(self.snake.parts.front().unwrap().x > window_x as i32) { [INFO] [stderr] 206 + if self.snake.parts.front().unwrap().x > window_x as i32 { [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: unnecessary parentheses around `if` condition [INFO] [stderr] --> src/main.rs:208:17 [INFO] [stderr] | [INFO] [stderr] 208 | }else if(self.snake.parts.front().unwrap().x < 0) { [INFO] [stderr] | ^ ^ [INFO] [stderr] | [INFO] [stderr] help: remove these parentheses [INFO] [stderr] | [INFO] [stderr] 208 - }else if(self.snake.parts.front().unwrap().x < 0) { [INFO] [stderr] 208 + }else if self.snake.parts.front().unwrap().x < 0 { [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: unnecessary parentheses around `if` condition [INFO] [stderr] --> src/main.rs:213:11 [INFO] [stderr] | [INFO] [stderr] 213 | if(self.snake.parts.front().unwrap().y > window_y as i32) { [INFO] [stderr] | ^ ^ [INFO] [stderr] | [INFO] [stderr] help: remove these parentheses [INFO] [stderr] | [INFO] [stderr] 213 - if(self.snake.parts.front().unwrap().y > window_y as i32) { [INFO] [stderr] 213 + if self.snake.parts.front().unwrap().y > window_y as i32 { [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: unnecessary parentheses around `if` condition [INFO] [stderr] --> src/main.rs:215:17 [INFO] [stderr] | [INFO] [stderr] 215 | }else if(self.snake.parts.front().unwrap().y < 0) { [INFO] [stderr] | ^ ^ [INFO] [stderr] | [INFO] [stderr] help: remove these parentheses [INFO] [stderr] | [INFO] [stderr] 215 - }else if(self.snake.parts.front().unwrap().y < 0) { [INFO] [stderr] 215 + }else if self.snake.parts.front().unwrap().y < 0 { [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: unused variable: `ctx` [INFO] [stderr] --> src/main.rs:265:33 [INFO] [stderr] | [INFO] [stderr] 265 | fn key_down_event(&mut self,ctx: &mut Context, keycode: KeyCode, keymods: KeyMods, repeat: bool) { [INFO] [stderr] | ^^^ help: if this is intentional, prefix it with an underscore: `_ctx` [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(unused_variables)]` on by default [INFO] [stderr] [INFO] [stderr] warning: unused variable: `keymods` [INFO] [stderr] --> src/main.rs:265:70 [INFO] [stderr] | [INFO] [stderr] 265 | fn key_down_event(&mut self,ctx: &mut Context, keycode: KeyCode, keymods: KeyMods, repeat: bool) { [INFO] [stderr] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_keymods` [INFO] [stderr] [INFO] [stderr] warning: unused variable: `repeat` [INFO] [stderr] --> src/main.rs:265:88 [INFO] [stderr] | [INFO] [stderr] 265 | fn key_down_event(&mut self,ctx: &mut Context, keycode: KeyCode, keymods: KeyMods, repeat: bool) { [INFO] [stderr] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_repeat` [INFO] [stderr] [INFO] [stderr] warning: cannot borrow `self.parts` as mutable because it is also borrowed as immutable [INFO] [stderr] --> src/main.rs:76:17 [INFO] [stderr] | [INFO] [stderr] 65 | let head_part: &Part = self.parts.back().unwrap(); [INFO] [stderr] | ----------------- immutable borrow occurs here [INFO] [stderr] ... [INFO] [stderr] 76 | self.parts.push_back(Part {x: head_part.x, y: head_part.y - 10}); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | | | [INFO] [stderr] | | immutable borrow later used here [INFO] [stderr] | mutable borrow occurs here [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(mutable_borrow_reservation_conflict)]` on by default [INFO] [stderr] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stderr] = note: for more information, see issue #59159 [INFO] [stderr] [INFO] [stderr] warning: cannot borrow `self.parts` as mutable because it is also borrowed as immutable [INFO] [stderr] --> src/main.rs:70:17 [INFO] [stderr] | [INFO] [stderr] 65 | let head_part: &Part = self.parts.back().unwrap(); [INFO] [stderr] | ----------------- immutable borrow occurs here [INFO] [stderr] ... [INFO] [stderr] 70 | self.parts.push_back(Part {x: head_part.x - 10, y: head_part.y}); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | | | [INFO] [stderr] | | immutable borrow later used here [INFO] [stderr] | mutable borrow occurs here [INFO] [stderr] | [INFO] [stderr] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stderr] = note: for more information, see issue #59159 [INFO] [stderr] [INFO] [stderr] warning: cannot borrow `self.parts` as mutable because it is also borrowed as immutable [INFO] [stderr] --> src/main.rs:79:17 [INFO] [stderr] | [INFO] [stderr] 65 | let head_part: &Part = self.parts.back().unwrap(); [INFO] [stderr] | ----------------- immutable borrow occurs here [INFO] [stderr] ... [INFO] [stderr] 79 | self.parts.push_back(Part {x: head_part.x, y: head_part.y + 10}); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | | | [INFO] [stderr] | | immutable borrow later used here [INFO] [stderr] | mutable borrow occurs here [INFO] [stderr] | [INFO] [stderr] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stderr] = note: for more information, see issue #59159 [INFO] [stderr] [INFO] [stderr] warning: cannot borrow `self.parts` as mutable because it is also borrowed as immutable [INFO] [stderr] --> src/main.rs:73:17 [INFO] [stderr] | [INFO] [stderr] 65 | let head_part: &Part = self.parts.back().unwrap(); [INFO] [stderr] | ----------------- immutable borrow occurs here [INFO] [stderr] ... [INFO] [stderr] 73 | self.parts.push_back(Part {x: head_part.x + 10, y: head_part.y}); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | | | [INFO] [stderr] | | immutable borrow later used here [INFO] [stderr] | mutable borrow occurs here [INFO] [stderr] | [INFO] [stderr] = warning: this borrowing pattern was not meant to be accepted, and may become a hard error in the future [INFO] [stderr] = note: for more information, see issue #59159 [INFO] [stderr] [INFO] [stderr] warning: variable does not need to be mutable [INFO] [stderr] --> src/main.rs:89:13 [INFO] [stderr] | [INFO] [stderr] 89 | let mut head: &mut Part = self.parts.front_mut().unwrap(); [INFO] [stderr] | ----^^^^ [INFO] [stderr] | | [INFO] [stderr] | help: remove this `mut` [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(unused_mut)]` on by default [INFO] [stderr] [INFO] [stderr] warning: associated function is never used: `new_op` [INFO] [stderr] --> src/main.rs:147:8 [INFO] [stderr] | [INFO] [stderr] 147 | fn new_op(r: u8, g: u8, b: u8, size: i32) -> Self { [INFO] [stderr] | ^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(dead_code)]` on by default [INFO] [stderr] [INFO] [stderr] warning: unused `Result` that must be used [INFO] [stderr] --> src/main.rs:255:9 [INFO] [stderr] | [INFO] [stderr] 255 | graphics::draw(ctx, &score, DrawParam::default()); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: `#[warn(unused_must_use)]` on by default [INFO] [stderr] = note: this `Result` may be an `Err` variant, which should be handled [INFO] [stderr] [INFO] [stderr] warning: unused `Result` that must be used [INFO] [stderr] --> src/main.rs:256:9 [INFO] [stderr] | [INFO] [stderr] 256 | graphics::draw(ctx, &highscore, DrawParam::default().dest(high_rect)); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: this `Result` may be an `Err` variant, which should be handled [INFO] [stderr] [INFO] [stderr] warning: `snake_game` (bin "snake_game" test) generated 16 warnings [INFO] [stderr] Finished test [unoptimized + debuginfo] target(s) in 0.26s [INFO] [stderr] Running unittests src/main.rs (/opt/rustwide/target/debug/deps/snake_game-dba92b6c4895a513) [INFO] [stdout] [INFO] [stdout] running 0 tests [INFO] [stdout] [INFO] [stdout] test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s [INFO] [stdout] [INFO] running `Command { std: "docker" "inspect" "0f99b963863d090091ae45820c0ad59123d0879b02734d618b90452e4223788b", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "0f99b963863d090091ae45820c0ad59123d0879b02734d618b90452e4223788b", kill_on_drop: false }` [INFO] [stdout] 0f99b963863d090091ae45820c0ad59123d0879b02734d618b90452e4223788b