[INFO] cloning repository https://github.com/ThomasBollmeier/rlox [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/ThomasBollmeier/rlox" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FThomasBollmeier%2Frlox", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FThomasBollmeier%2Frlox'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 8d5411b52d794b1cca132a4b6bb359be8bf6a639 [INFO] linting ThomasBollmeier/rlox against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FThomasBollmeier%2Frlox" "/workspace/builds/worker-2-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-2-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/ThomasBollmeier/rlox [INFO] finished tweaking git repo https://github.com/ThomasBollmeier/rlox [INFO] tweaked toml for git repo https://github.com/ThomasBollmeier/rlox written to /workspace/builds/worker-2-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/ThomasBollmeier/rlox on toolchain nightly [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] crate git repo https://github.com/ThomasBollmeier/rlox 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" "+nightly" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-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:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+nightly" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 84c5f315080c05fdabe17f0274400dbff8395acd99fca0ee99eadeec8505daaf [INFO] running `Command { std: "docker" "start" "-a" "84c5f315080c05fdabe17f0274400dbff8395acd99fca0ee99eadeec8505daaf", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "84c5f315080c05fdabe17f0274400dbff8395acd99fca0ee99eadeec8505daaf", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "84c5f315080c05fdabe17f0274400dbff8395acd99fca0ee99eadeec8505daaf", kill_on_drop: false }` [INFO] [stdout] 84c5f315080c05fdabe17f0274400dbff8395acd99fca0ee99eadeec8505daaf [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+nightly" "clippy" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 0f9bd95f5cd51cd45e59afca5c78f318152319048de7e9758925521aba7b00ff [INFO] running `Command { std: "docker" "start" "-a" "0f9bd95f5cd51cd45e59afca5c78f318152319048de7e9758925521aba7b00ff", kill_on_drop: false }` [INFO] [stderr] Checking rlox v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> src/frontend/interpreter.rs:15:17 [INFO] [stdout] | [INFO] [stdout] 15 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `trace_run` [INFO] [stdout] --> src/backend/vm.rs:118:21 [INFO] [stdout] | [INFO] [stdout] 118 | if cfg!(trace_run) { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: expected names are: `docsrs`, `feature`, and `test` and 31 more [INFO] [stdout] = help: consider using a Cargo feature instead [INFO] [stdout] = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint: [INFO] [stdout] [lints.rust] [INFO] [stdout] unexpected_cfgs = { level = "warn", check-cfg = ['cfg(trace_run)'] } [INFO] [stdout] = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(trace_run)");` to the top of the `build.rs` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: `#[warn(unexpected_cfgs)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> src/frontend/interpreter.rs:15:17 [INFO] [stdout] | [INFO] [stdout] 15 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `trace_run` [INFO] [stdout] --> src/backend/vm.rs:118:21 [INFO] [stdout] | [INFO] [stdout] 118 | if cfg!(trace_run) { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: expected names are: `docsrs`, `feature`, and `test` and 31 more [INFO] [stdout] = help: consider using a Cargo feature instead [INFO] [stdout] = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint: [INFO] [stdout] [lints.rust] [INFO] [stdout] unexpected_cfgs = { level = "warn", check-cfg = ['cfg(trace_run)'] } [INFO] [stdout] = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(trace_run)");` to the top of the `build.rs` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: `#[warn(unexpected_cfgs)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this loop could be written as a `while let` loop [INFO] [stdout] --> src/frontend/scanner.rs:110:9 [INFO] [stdout] | [INFO] [stdout] 110 | / loop { [INFO] [stdout] 111 | | if let Some(ch) = self.peek(0) { [INFO] [stdout] 112 | | if ch.is_alphanumeric() || ch == '_' { [INFO] [stdout] 113 | | self.current_lexeme.push(ch); [INFO] [stdout] ... | [INFO] [stdout] 121 | | } [INFO] [stdout] | |_________^ help: try: `while let Some(ch) = self.peek(0) { .. }` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#while_let_loop [INFO] [stdout] = note: `#[warn(clippy::while_let_loop)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `TokenType` which implements the `Copy` trait [INFO] [stdout] --> src/frontend/scanner.rs:129:13 [INFO] [stdout] | [INFO] [stdout] 129 | token_type.clone(), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: try dereferencing it: `*token_type` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] = note: `#[warn(clippy::clone_on_copy)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/frontend/scanner.rs:190:9 [INFO] [stdout] | [INFO] [stdout] 190 | / return Token::new( [INFO] [stdout] 191 | | TokenType::Number, [INFO] [stdout] 192 | | self.current_lexeme.clone(), [INFO] [stdout] 193 | | self.current_line) [INFO] [stdout] | |______________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] = note: `#[warn(clippy::needless_return)]` on by default [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 190 ~ Token::new( [INFO] [stdout] 191 + TokenType::Number, [INFO] [stdout] 192 + self.current_lexeme.clone(), [INFO] [stdout] 193 + self.current_line) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this loop could be written as a `while let` loop [INFO] [stdout] --> src/frontend/scanner.rs:136:9 [INFO] [stdout] | [INFO] [stdout] 136 | / loop { [INFO] [stdout] 137 | | if let Some(ch) = self.peek(0) { [INFO] [stdout] 138 | | if ch.is_numeric() { [INFO] [stdout] 139 | | self.current_lexeme.push(ch); [INFO] [stdout] ... | [INFO] [stdout] 150 | | } [INFO] [stdout] | |_________^ help: try: `while let Some(ch) = self.peek(0) { .. }` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#while_let_loop [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this loop could be written as a `while let` loop [INFO] [stdout] --> src/frontend/scanner.rs:110:9 [INFO] [stdout] | [INFO] [stdout] 110 | / loop { [INFO] [stdout] 111 | | if let Some(ch) = self.peek(0) { [INFO] [stdout] 112 | | if ch.is_alphanumeric() || ch == '_' { [INFO] [stdout] 113 | | self.current_lexeme.push(ch); [INFO] [stdout] ... | [INFO] [stdout] 121 | | } [INFO] [stdout] | |_________^ help: try: `while let Some(ch) = self.peek(0) { .. }` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#while_let_loop [INFO] [stdout] = note: `#[warn(clippy::while_let_loop)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this loop could be written as a `while let` loop [INFO] [stdout] --> src/frontend/scanner.rs:177:9 [INFO] [stdout] | [INFO] [stdout] 177 | / loop { [INFO] [stdout] 178 | | if let Some(ch) = self.peek(0) { [INFO] [stdout] 179 | | if ch.is_numeric() { [INFO] [stdout] 180 | | self.current_lexeme.push(ch); [INFO] [stdout] ... | [INFO] [stdout] 188 | | } [INFO] [stdout] | |_________^ help: try: `while let Some(ch) = self.peek(0) { .. }` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#while_let_loop [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this loop could be written as a `while let` loop [INFO] [stdout] --> src/frontend/scanner.rs:279:9 [INFO] [stdout] | [INFO] [stdout] 279 | / loop { [INFO] [stdout] 280 | | if let Some(ch) = self.peek(0) { [INFO] [stdout] 281 | | if ch != '\n' { [INFO] [stdout] 282 | | self.advance(); [INFO] [stdout] ... | [INFO] [stdout] 289 | | } [INFO] [stdout] | |_________^ help: try: `while let Some(ch) = self.peek(0) { .. }` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#while_let_loop [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `TokenType` which implements the `Copy` trait [INFO] [stdout] --> src/frontend/scanner.rs:129:13 [INFO] [stdout] | [INFO] [stdout] 129 | token_type.clone(), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: try dereferencing it: `*token_type` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] = note: `#[warn(clippy::clone_on_copy)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/frontend/scanner.rs:190:9 [INFO] [stdout] | [INFO] [stdout] 190 | / return Token::new( [INFO] [stdout] 191 | | TokenType::Number, [INFO] [stdout] 192 | | self.current_lexeme.clone(), [INFO] [stdout] 193 | | self.current_line) [INFO] [stdout] | |______________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] = note: `#[warn(clippy::needless_return)]` on by default [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 190 ~ Token::new( [INFO] [stdout] 191 + TokenType::Number, [INFO] [stdout] 192 + self.current_lexeme.clone(), [INFO] [stdout] 193 + self.current_line) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this loop could be written as a `while let` loop [INFO] [stdout] --> src/frontend/scanner.rs:136:9 [INFO] [stdout] | [INFO] [stdout] 136 | / loop { [INFO] [stdout] 137 | | if let Some(ch) = self.peek(0) { [INFO] [stdout] 138 | | if ch.is_numeric() { [INFO] [stdout] 139 | | self.current_lexeme.push(ch); [INFO] [stdout] ... | [INFO] [stdout] 150 | | } [INFO] [stdout] | |_________^ help: try: `while let Some(ch) = self.peek(0) { .. }` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#while_let_loop [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this loop could be written as a `while let` loop [INFO] [stdout] --> src/frontend/scanner.rs:177:9 [INFO] [stdout] | [INFO] [stdout] 177 | / loop { [INFO] [stdout] 178 | | if let Some(ch) = self.peek(0) { [INFO] [stdout] 179 | | if ch.is_numeric() { [INFO] [stdout] 180 | | self.current_lexeme.push(ch); [INFO] [stdout] ... | [INFO] [stdout] 188 | | } [INFO] [stdout] | |_________^ help: try: `while let Some(ch) = self.peek(0) { .. }` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#while_let_loop [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this loop could be written as a `while let` loop [INFO] [stdout] --> src/frontend/scanner.rs:279:9 [INFO] [stdout] | [INFO] [stdout] 279 | / loop { [INFO] [stdout] 280 | | if let Some(ch) = self.peek(0) { [INFO] [stdout] 281 | | if ch != '\n' { [INFO] [stdout] 282 | | self.advance(); [INFO] [stdout] ... | [INFO] [stdout] 289 | | } [INFO] [stdout] | |_________^ help: try: `while let Some(ch) = self.peek(0) { .. }` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#while_let_loop [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/frontend/compiler.rs:278:12 [INFO] [stdout] | [INFO] [stdout] 278 | if !idx_opt.is_none() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: try: `idx_opt.is_some()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/frontend/compiler.rs:278:12 [INFO] [stdout] | [INFO] [stdout] 278 | if !idx_opt.is_none() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: try: `idx_opt.is_some()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/frontend/compiler.rs:349:12 [INFO] [stdout] | [INFO] [stdout] 349 | if !idx_opt.is_none() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: try: `idx_opt.is_some()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/frontend/compiler.rs:349:12 [INFO] [stdout] | [INFO] [stdout] 349 | if !idx_opt.is_none() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: try: `idx_opt.is_some()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `jump_opt` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:525:45 [INFO] [stdout] | [INFO] [stdout] 523 | if jump_opt.is_some() { [INFO] [stdout] | --------------------- help: try: `if let Some() = jump_opt` [INFO] [stdout] 524 | let body = chunk.size(); [INFO] [stdout] 525 | self.update_forward_jump(chunk, jump_opt.unwrap(), body); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] = note: `#[warn(clippy::unnecessary_unwrap)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `incr_opt` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:531:13 [INFO] [stdout] | [INFO] [stdout] 530 | let jump_target = if incr_opt.is_some() { [INFO] [stdout] | --------------------- help: try: `if let Some() = incr_opt` [INFO] [stdout] 531 | incr_opt.unwrap() [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `cond_false_opt` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:542:30 [INFO] [stdout] | [INFO] [stdout] 540 | if cond_false_opt.is_some() { [INFO] [stdout] | --------------------------- help: try: `if let Some() = cond_false_opt` [INFO] [stdout] 541 | let after_loop = chunk.size(); [INFO] [stdout] 542 | let cond_false = cond_false_opt.unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `jump_opt` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:525:45 [INFO] [stdout] | [INFO] [stdout] 523 | if jump_opt.is_some() { [INFO] [stdout] | --------------------- help: try: `if let Some() = jump_opt` [INFO] [stdout] 524 | let body = chunk.size(); [INFO] [stdout] 525 | self.update_forward_jump(chunk, jump_opt.unwrap(), body); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] = note: `#[warn(clippy::unnecessary_unwrap)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `incr_opt` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:531:13 [INFO] [stdout] | [INFO] [stdout] 530 | let jump_target = if incr_opt.is_some() { [INFO] [stdout] | --------------------- help: try: `if let Some() = incr_opt` [INFO] [stdout] 531 | incr_opt.unwrap() [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `cond_false_opt` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:542:30 [INFO] [stdout] | [INFO] [stdout] 540 | if cond_false_opt.is_some() { [INFO] [stdout] | --------------------------- help: try: `if let Some() = cond_false_opt` [INFO] [stdout] 541 | let after_loop = chunk.size(); [INFO] [stdout] 542 | let cond_false = cond_false_opt.unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `check_eq_opt` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:652:32 [INFO] [stdout] | [INFO] [stdout] 651 | if check_eq_opt.is_some() { [INFO] [stdout] | ------------------------- help: try: `if let Some() = check_eq_opt` [INFO] [stdout] 652 | let from = check_eq_opt.unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `check_eq_opt` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:690:24 [INFO] [stdout] | [INFO] [stdout] 689 | if check_eq_opt.is_some() { [INFO] [stdout] | ------------------------- help: try: `if let Some() = check_eq_opt` [INFO] [stdout] 690 | let from = check_eq_opt.unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `check_eq_opt` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:652:32 [INFO] [stdout] | [INFO] [stdout] 651 | if check_eq_opt.is_some() { [INFO] [stdout] | ------------------------- help: try: `if let Some() = check_eq_opt` [INFO] [stdout] 652 | let from = check_eq_opt.unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `check_eq_opt` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:690:24 [INFO] [stdout] | [INFO] [stdout] 689 | if check_eq_opt.is_some() { [INFO] [stdout] | ------------------------- help: try: `if let Some() = check_eq_opt` [INFO] [stdout] 690 | let from = check_eq_opt.unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `last_loop` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:827:29 [INFO] [stdout] | [INFO] [stdout] 826 | if last_loop.is_some() { [INFO] [stdout] | ---------------------- help: try: `if let Some() = last_loop` [INFO] [stdout] 827 | let loop_data = last_loop.unwrap().clone(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `local_idx` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:898:59 [INFO] [stdout] | [INFO] [stdout] 896 | if local_idx.is_some() { [INFO] [stdout] | ---------------------- help: try: `if let Some() = local_idx` [INFO] [stdout] 897 | self.emit_instruction(chunk, [INFO] [stdout] 898 | Instruction::GetLocal {local_idx: local_idx.unwrap() }); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `local_idx` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:907:59 [INFO] [stdout] | [INFO] [stdout] 905 | if local_idx.is_some() { [INFO] [stdout] | ---------------------- help: try: `if let Some() = local_idx` [INFO] [stdout] 906 | self.emit_instruction(chunk, [INFO] [stdout] 907 | Instruction::SetLocal {local_idx: local_idx.unwrap() }); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `last_loop` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:827:29 [INFO] [stdout] | [INFO] [stdout] 826 | if last_loop.is_some() { [INFO] [stdout] | ---------------------- help: try: `if let Some() = last_loop` [INFO] [stdout] 827 | let loop_data = last_loop.unwrap().clone(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `local_idx` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:898:59 [INFO] [stdout] | [INFO] [stdout] 896 | if local_idx.is_some() { [INFO] [stdout] | ---------------------- help: try: `if let Some() = local_idx` [INFO] [stdout] 897 | self.emit_instruction(chunk, [INFO] [stdout] 898 | Instruction::GetLocal {local_idx: local_idx.unwrap() }); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `local_idx` after checking its variant with `is_some` [INFO] [stdout] --> src/frontend/compiler.rs:907:59 [INFO] [stdout] | [INFO] [stdout] 905 | if local_idx.is_some() { [INFO] [stdout] | ---------------------- help: try: `if let Some() = local_idx` [INFO] [stdout] 906 | self.emit_instruction(chunk, [INFO] [stdout] 907 | Instruction::SetLocal {local_idx: local_idx.unwrap() }); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this if-then-else expression returns a bool literal [INFO] [stdout] --> src/frontend/compiler.rs:1097:13 [INFO] [stdout] | [INFO] [stdout] 1097 | / if current.get_token_type() == expected_type { [INFO] [stdout] 1098 | | true [INFO] [stdout] 1099 | | } else { [INFO] [stdout] 1100 | | false [INFO] [stdout] 1101 | | } [INFO] [stdout] | |_____________^ help: you can reduce it to: `current.get_token_type() == expected_type` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_bool [INFO] [stdout] = note: `#[warn(clippy::needless_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this if-then-else expression returns a bool literal [INFO] [stdout] --> src/frontend/compiler.rs:1097:13 [INFO] [stdout] | [INFO] [stdout] 1097 | / if current.get_token_type() == expected_type { [INFO] [stdout] 1098 | | true [INFO] [stdout] 1099 | | } else { [INFO] [stdout] 1100 | | false [INFO] [stdout] 1101 | | } [INFO] [stdout] | |_____________^ help: you can reduce it to: `current.get_token_type() == expected_type` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_bool [INFO] [stdout] = note: `#[warn(clippy::needless_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `Precedence` which implements the `Copy` trait [INFO] [stdout] --> src/frontend/parse_rules.rs:29:13 [INFO] [stdout] | [INFO] [stdout] 29 | self.clone() [INFO] [stdout] | ^^^^^^^^^^^^ help: try dereferencing it: `*self` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `ParseRules` [INFO] [stdout] --> src/frontend/parse_rules.rs:71:5 [INFO] [stdout] | [INFO] [stdout] 71 | / pub fn new() -> ParseRules { [INFO] [stdout] 72 | | ParseRules { rules: HashMap::new() } [INFO] [stdout] 73 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] = note: `#[warn(clippy::new_without_default)]` on by default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 69 + impl Default for ParseRules { [INFO] [stdout] 70 + fn default() -> Self { [INFO] [stdout] 71 + Self::new() [INFO] [stdout] 72 + } [INFO] [stdout] 73 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `Precedence` which implements the `Copy` trait [INFO] [stdout] --> src/frontend/parse_rules.rs:29:13 [INFO] [stdout] | [INFO] [stdout] 29 | self.clone() [INFO] [stdout] | ^^^^^^^^^^^^ help: try dereferencing it: `*self` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `ParseRules` [INFO] [stdout] --> src/frontend/parse_rules.rs:71:5 [INFO] [stdout] | [INFO] [stdout] 71 | / pub fn new() -> ParseRules { [INFO] [stdout] 72 | | ParseRules { rules: HashMap::new() } [INFO] [stdout] 73 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] = note: `#[warn(clippy::new_without_default)]` on by default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 69 + impl Default for ParseRules { [INFO] [stdout] 70 + fn default() -> Self { [INFO] [stdout] 71 + Self::new() [INFO] [stdout] 72 + } [INFO] [stdout] 73 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `Chunk` [INFO] [stdout] --> src/backend/chunk.rs:15:5 [INFO] [stdout] | [INFO] [stdout] 15 | / pub fn new() -> Chunk { [INFO] [stdout] 16 | | Chunk::new_with_capacity(0) [INFO] [stdout] 17 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 13 + impl Default for Chunk { [INFO] [stdout] 14 + fn default() -> Self { [INFO] [stdout] 15 + Self::new() [INFO] [stdout] 16 + } [INFO] [stdout] 17 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `Chunk` [INFO] [stdout] --> src/backend/chunk.rs:15:5 [INFO] [stdout] | [INFO] [stdout] 15 | / pub fn new() -> Chunk { [INFO] [stdout] 16 | | Chunk::new_with_capacity(0) [INFO] [stdout] 17 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 13 + impl Default for Chunk { [INFO] [stdout] 14 + fn default() -> Self { [INFO] [stdout] 15 + Self::new() [INFO] [stdout] 16 + } [INFO] [stdout] 17 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this block may be rewritten with the `?` operator [INFO] [stdout] --> src/backend/chunk.rs:184:9 [INFO] [stdout] | [INFO] [stdout] 184 | / if op_code_opt.is_none() { [INFO] [stdout] 185 | | return None; [INFO] [stdout] 186 | | } [INFO] [stdout] | |_________^ help: replace it with: `op_code_opt?;` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#question_mark [INFO] [stdout] = note: `#[warn(clippy::question_mark)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u8` which implements the `Copy` trait [INFO] [stdout] --> src/backend/chunk.rs:188:23 [INFO] [stdout] | [INFO] [stdout] 188 | let op_code = op_code_opt.unwrap().clone(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try dereferencing it: `*op_code_opt.unwrap()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `Option::map` [INFO] [stdout] --> src/backend/chunk.rs:199:17 [INFO] [stdout] | [INFO] [stdout] 199 | / match value_idx_opt { [INFO] [stdout] 200 | | Some(value_idx) => [INFO] [stdout] 201 | | Some((Instruction::Constant { value_idx: value_idx.clone() }, next_offset)), [INFO] [stdout] 202 | | None => None [INFO] [stdout] 203 | | } [INFO] [stdout] | |_________________^ help: try: `value_idx_opt.map(|value_idx| (Instruction::Constant { value_idx: value_idx.clone() }, next_offset))` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_map [INFO] [stdout] = note: `#[warn(clippy::manual_map)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u8` which implements the `Copy` trait [INFO] [stdout] --> src/backend/chunk.rs:201:66 [INFO] [stdout] | [INFO] [stdout] 201 | Some((Instruction::Constant { value_idx: value_idx.clone() }, next_offset)), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: try dereferencing it: `*value_idx` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u32` which implements the `Copy` trait [INFO] [stdout] --> src/backend/chunk.rs:208:62 [INFO] [stdout] | [INFO] [stdout] 208 | Some((Instruction::ConstantLong { value_idx: value_idx.clone() }, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: try removing the `clone` call: `value_idx` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this block may be rewritten with the `?` operator [INFO] [stdout] --> src/backend/chunk.rs:184:9 [INFO] [stdout] | [INFO] [stdout] 184 | / if op_code_opt.is_none() { [INFO] [stdout] 185 | | return None; [INFO] [stdout] 186 | | } [INFO] [stdout] | |_________^ help: replace it with: `op_code_opt?;` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#question_mark [INFO] [stdout] = note: `#[warn(clippy::question_mark)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u8` which implements the `Copy` trait [INFO] [stdout] --> src/backend/chunk.rs:188:23 [INFO] [stdout] | [INFO] [stdout] 188 | let op_code = op_code_opt.unwrap().clone(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try dereferencing it: `*op_code_opt.unwrap()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u8` which implements the `Copy` trait [INFO] [stdout] --> src/backend/chunk.rs:286:40 [INFO] [stdout] | [INFO] [stdout] 286 | let num_args = num_args.clone(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: try dereferencing it: `*num_args` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `Option::map` [INFO] [stdout] --> src/backend/chunk.rs:199:17 [INFO] [stdout] | [INFO] [stdout] 199 | / match value_idx_opt { [INFO] [stdout] 200 | | Some(value_idx) => [INFO] [stdout] 201 | | Some((Instruction::Constant { value_idx: value_idx.clone() }, next_offset)), [INFO] [stdout] 202 | | None => None [INFO] [stdout] 203 | | } [INFO] [stdout] | |_________________^ help: try: `value_idx_opt.map(|value_idx| (Instruction::Constant { value_idx: value_idx.clone() }, next_offset))` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_map [INFO] [stdout] = note: `#[warn(clippy::manual_map)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u8` which implements the `Copy` trait [INFO] [stdout] --> src/backend/chunk.rs:201:66 [INFO] [stdout] | [INFO] [stdout] 201 | Some((Instruction::Constant { value_idx: value_idx.clone() }, next_offset)), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: try dereferencing it: `*value_idx` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u32` which implements the `Copy` trait [INFO] [stdout] --> src/backend/chunk.rs:208:62 [INFO] [stdout] | [INFO] [stdout] 208 | Some((Instruction::ConstantLong { value_idx: value_idx.clone() }, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: try removing the `clone` call: `value_idx` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `i32` which implements the `Copy` trait [INFO] [stdout] --> src/backend/chunk.rs:327:29 [INFO] [stdout] | [INFO] [stdout] 327 | return Some(line.clone()); [INFO] [stdout] | ^^^^^^^^^^^^ help: try dereferencing it: `*line` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `u8` which implements the `Copy` trait [INFO] [stdout] --> src/backend/chunk.rs:286:40 [INFO] [stdout] | [INFO] [stdout] 286 | let num_args = num_args.clone(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: try dereferencing it: `*num_args` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `i32` which implements the `Copy` trait [INFO] [stdout] --> src/backend/chunk.rs:327:29 [INFO] [stdout] | [INFO] [stdout] 327 | return Some(line.clone()); [INFO] [stdout] | ^^^^^^^^^^^^ help: try dereferencing it: `*line` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `f64` which implements the `Copy` trait [INFO] [stdout] --> src/backend/value.rs:42:47 [INFO] [stdout] | [INFO] [stdout] 42 | Self::Number(val) => Self::Number(val.clone()), [INFO] [stdout] | ^^^^^^^^^^^ help: try dereferencing it: `*val` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `bool` which implements the `Copy` trait [INFO] [stdout] --> src/backend/value.rs:43:43 [INFO] [stdout] | [INFO] [stdout] 43 | Self::Bool(val) => Self::Bool(val.clone()), [INFO] [stdout] | ^^^^^^^^^^^ help: try dereferencing it: `*val` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `VM` [INFO] [stdout] --> src/backend/vm.rs:45:5 [INFO] [stdout] | [INFO] [stdout] 45 | / pub fn new() -> VM { [INFO] [stdout] 46 | | VM::new_with_frame(CallFrame::new_top()) [INFO] [stdout] 47 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 44 + impl Default for VM { [INFO] [stdout] 45 + fn default() -> Self { [INFO] [stdout] 46 + Self::new() [INFO] [stdout] 47 + } [INFO] [stdout] 48 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: returning the result of a `let` binding from a block [INFO] [stdout] --> src/backend/vm.rs:75:9 [INFO] [stdout] | [INFO] [stdout] 74 | let ret = current_frame.ip; [INFO] [stdout] | --------------------------- unnecessary `let` binding [INFO] [stdout] 75 | ret [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_and_return [INFO] [stdout] = note: `#[warn(clippy::let_and_return)]` on by default [INFO] [stdout] help: return the expression directly [INFO] [stdout] | [INFO] [stdout] 74 ~ [INFO] [stdout] 75 ~ current_frame.ip [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: returning the result of a `let` binding from a block [INFO] [stdout] --> src/backend/vm.rs:81:9 [INFO] [stdout] | [INFO] [stdout] 80 | let ret = current_frame.stack_base; [INFO] [stdout] | ----------------------------------- unnecessary `let` binding [INFO] [stdout] 81 | ret [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_and_return [INFO] [stdout] help: return the expression directly [INFO] [stdout] | [INFO] [stdout] 80 ~ [INFO] [stdout] 81 ~ current_frame.stack_base [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `f64` which implements the `Copy` trait [INFO] [stdout] --> src/backend/value.rs:42:47 [INFO] [stdout] | [INFO] [stdout] 42 | Self::Number(val) => Self::Number(val.clone()), [INFO] [stdout] | ^^^^^^^^^^^ help: try dereferencing it: `*val` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `bool` which implements the `Copy` trait [INFO] [stdout] --> src/backend/value.rs:43:43 [INFO] [stdout] | [INFO] [stdout] 43 | Self::Bool(val) => Self::Bool(val.clone()), [INFO] [stdout] | ^^^^^^^^^^^ help: try dereferencing it: `*val` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `VM` [INFO] [stdout] --> src/backend/vm.rs:45:5 [INFO] [stdout] | [INFO] [stdout] 45 | / pub fn new() -> VM { [INFO] [stdout] 46 | | VM::new_with_frame(CallFrame::new_top()) [INFO] [stdout] 47 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 44 + impl Default for VM { [INFO] [stdout] 45 + fn default() -> Self { [INFO] [stdout] 46 + Self::new() [INFO] [stdout] 47 + } [INFO] [stdout] 48 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `Option::map` [INFO] [stdout] --> src/backend/vm.rs:220:9 [INFO] [stdout] | [INFO] [stdout] 220 | / match stack.get(index) { [INFO] [stdout] 221 | | Some(value) => Some(value.clone()), [INFO] [stdout] 222 | | None => None, [INFO] [stdout] 223 | | } [INFO] [stdout] | |_________^ help: try: `stack.get(index).map(|value| value.clone())` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_map [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: returning the result of a `let` binding from a block [INFO] [stdout] --> src/backend/vm.rs:75:9 [INFO] [stdout] | [INFO] [stdout] 74 | let ret = current_frame.ip; [INFO] [stdout] | --------------------------- unnecessary `let` binding [INFO] [stdout] 75 | ret [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_and_return [INFO] [stdout] = note: `#[warn(clippy::let_and_return)]` on by default [INFO] [stdout] help: return the expression directly [INFO] [stdout] | [INFO] [stdout] 74 ~ [INFO] [stdout] 75 ~ current_frame.ip [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: returning the result of a `let` binding from a block [INFO] [stdout] --> src/backend/vm.rs:81:9 [INFO] [stdout] | [INFO] [stdout] 80 | let ret = current_frame.stack_base; [INFO] [stdout] | ----------------------------------- unnecessary `let` binding [INFO] [stdout] 81 | ret [INFO] [stdout] | ^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_and_return [INFO] [stdout] help: return the expression directly [INFO] [stdout] | [INFO] [stdout] 80 ~ [INFO] [stdout] 81 ~ current_frame.stack_base [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `varvalue` after checking its variant with `is_some` [INFO] [stdout] --> src/backend/vm.rs:321:31 [INFO] [stdout] | [INFO] [stdout] 320 | if varvalue.is_some() { [INFO] [stdout] | --------------------- help: try: `if let Some() = varvalue` [INFO] [stdout] 321 | self.push(varvalue.unwrap()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: usage of `contains_key` followed by `insert` on a `HashMap` [INFO] [stdout] --> src/backend/vm.rs:348:17 [INFO] [stdout] | [INFO] [stdout] 348 | / if globals.contains_key(&varname) { [INFO] [stdout] 349 | | let new_value = self.peek(0).unwrap(); [INFO] [stdout] 350 | | globals.insert(varname, new_value); [INFO] [stdout] 351 | | } else { [INFO] [stdout] ... | [INFO] [stdout] 354 | | return Some(InterpretResult::RuntimeError); [INFO] [stdout] 355 | | } [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider using the `Entry` API: https://doc.rust-lang.org/std/collections/struct.HashMap.html#entry-api [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_entry [INFO] [stdout] = note: `#[warn(clippy::map_entry)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `Option::map` [INFO] [stdout] --> src/backend/vm.rs:220:9 [INFO] [stdout] | [INFO] [stdout] 220 | / match stack.get(index) { [INFO] [stdout] 221 | | Some(value) => Some(value.clone()), [INFO] [stdout] 222 | | None => None, [INFO] [stdout] 223 | | } [INFO] [stdout] | |_________^ help: try: `stack.get(index).map(|value| value.clone())` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_map [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `varvalue` after checking its variant with `is_some` [INFO] [stdout] --> src/backend/vm.rs:321:31 [INFO] [stdout] | [INFO] [stdout] 320 | if varvalue.is_some() { [INFO] [stdout] | --------------------- help: try: `if let Some() = varvalue` [INFO] [stdout] 321 | self.push(varvalue.unwrap()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: usage of `contains_key` followed by `insert` on a `HashMap` [INFO] [stdout] --> src/backend/vm.rs:348:17 [INFO] [stdout] | [INFO] [stdout] 348 | / if globals.contains_key(&varname) { [INFO] [stdout] 349 | | let new_value = self.peek(0).unwrap(); [INFO] [stdout] 350 | | globals.insert(varname, new_value); [INFO] [stdout] 351 | | } else { [INFO] [stdout] ... | [INFO] [stdout] 354 | | return Some(InterpretResult::RuntimeError); [INFO] [stdout] 355 | | } [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider using the `Entry` API: https://doc.rust-lang.org/std/collections/struct.HashMap.html#entry-api [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_entry [INFO] [stdout] = note: `#[warn(clippy::map_entry)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: match expression looks like `matches!` macro [INFO] [stdout] --> src/backend/vm.rs:529:9 [INFO] [stdout] | [INFO] [stdout] 529 | / match value { [INFO] [stdout] 530 | | Value::Nil => true, [INFO] [stdout] 531 | | Value::Bool(false) => true, [INFO] [stdout] 532 | | _ => false [INFO] [stdout] 533 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro [INFO] [stdout] = note: `#[warn(clippy::match_like_matches_macro)]` on by default [INFO] [stdout] help: use `matches!` directly [INFO] [stdout] | [INFO] [stdout] 529 - match value { [INFO] [stdout] 530 - Value::Nil => true, [INFO] [stdout] 531 - Value::Bool(false) => true, [INFO] [stdout] 532 - _ => false [INFO] [stdout] 533 - } [INFO] [stdout] 529 + matches!(value, Value::Nil | Value::Bool(false)) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `new_string_opt` after checking its variant with `is_none` [INFO] [stdout] --> src/backend/vm.rs:571:43 [INFO] [stdout] | [INFO] [stdout] 568 | if new_string_opt.is_none() { [INFO] [stdout] | --------------------------- help: try: `if let Some() = new_string_opt` [INFO] [stdout] ... [INFO] [stdout] 571 | self.push(&Value::Str(new_string_opt.unwrap())); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `HeapManager` [INFO] [stdout] --> src/backend/heap.rs:58:5 [INFO] [stdout] | [INFO] [stdout] 58 | / pub fn new() -> HeapManager { [INFO] [stdout] 59 | | HeapManager { [INFO] [stdout] 60 | | objects: vec![], [INFO] [stdout] 61 | | free_slots: vec![], [INFO] [stdout] 62 | | } [INFO] [stdout] 63 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 56 + impl Default for HeapManager { [INFO] [stdout] 57 + fn default() -> Self { [INFO] [stdout] 58 + Self::new() [INFO] [stdout] 59 + } [INFO] [stdout] 60 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: match expression looks like `matches!` macro [INFO] [stdout] --> src/backend/vm.rs:529:9 [INFO] [stdout] | [INFO] [stdout] 529 | / match value { [INFO] [stdout] 530 | | Value::Nil => true, [INFO] [stdout] 531 | | Value::Bool(false) => true, [INFO] [stdout] 532 | | _ => false [INFO] [stdout] 533 | | } [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro [INFO] [stdout] = note: `#[warn(clippy::match_like_matches_macro)]` on by default [INFO] [stdout] help: use `matches!` directly [INFO] [stdout] | [INFO] [stdout] 529 - match value { [INFO] [stdout] 530 - Value::Nil => true, [INFO] [stdout] 531 - Value::Bool(false) => true, [INFO] [stdout] 532 - _ => false [INFO] [stdout] 533 - } [INFO] [stdout] 529 + matches!(value, Value::Nil | Value::Bool(false)) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `new_string_opt` after checking its variant with `is_none` [INFO] [stdout] --> src/backend/vm.rs:571:43 [INFO] [stdout] | [INFO] [stdout] 568 | if new_string_opt.is_none() { [INFO] [stdout] | --------------------------- help: try: `if let Some() = new_string_opt` [INFO] [stdout] ... [INFO] [stdout] 571 | self.push(&Value::Str(new_string_opt.unwrap())); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/backend/native.rs:29:29 [INFO] [stdout] | [INFO] [stdout] 29 | Ok(Value::Str(s1.concat(&s2))) [INFO] [stdout] | ^^^ help: change this to: `s2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/frontend/scanner.rs:15:24 [INFO] [stdout] | [INFO] [stdout] 15 | pub fn new(source: &str) -> Scanner { [INFO] [stdout] | ^^^^ ^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] = note: `#[warn(mismatched_lifetime_syntaxes)]` on by default [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 15 | pub fn new(source: &str) -> Scanner<'_> { [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's named elsewhere is confusing [INFO] [stdout] --> src/frontend/compiler.rs:36:36 [INFO] [stdout] | [INFO] [stdout] 36 | pub fn new(source: &'a str) -> Compiler { [INFO] [stdout] | -- ^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is named here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: consistently use `'a` [INFO] [stdout] | [INFO] [stdout] 36 | pub fn new(source: &'a str) -> Compiler<'a> { [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `HeapManager` [INFO] [stdout] --> src/backend/heap.rs:58:5 [INFO] [stdout] | [INFO] [stdout] 58 | / pub fn new() -> HeapManager { [INFO] [stdout] 59 | | HeapManager { [INFO] [stdout] 60 | | objects: vec![], [INFO] [stdout] 61 | | free_slots: vec![], [INFO] [stdout] 62 | | } [INFO] [stdout] 63 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 56 + impl Default for HeapManager { [INFO] [stdout] 57 + fn default() -> Self { [INFO] [stdout] 58 + Self::new() [INFO] [stdout] 59 + } [INFO] [stdout] 60 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/backend/chunk.rs:334:35 [INFO] [stdout] | [INFO] [stdout] 334 | pub fn instruction_iter(self: &Chunk) -> InstructionIter { [INFO] [stdout] | ^^^^^^ ^^^^^^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 334 | pub fn instruction_iter(self: &Chunk) -> InstructionIter<'_> { [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/backend/vm.rs:62:20 [INFO] [stdout] | [INFO] [stdout] 62 | fn current_fun(&self) -> Ref { [INFO] [stdout] | ^^^^^ ^^^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 62 | fn current_fun(&self) -> Ref<'_, FunData> { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/backend/vm.rs:67:24 [INFO] [stdout] | [INFO] [stdout] 67 | fn current_fun_mut(&mut self) -> RefMut { [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 67 | fn current_fun_mut(&mut self) -> RefMut<'_, FunData> { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/backend/objects.rs:54:25 [INFO] [stdout] | [INFO] [stdout] 54 | pub fn borrow_chunk(&self) -> Ref { [INFO] [stdout] | ^^^^^ ^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 54 | pub fn borrow_chunk(&self) -> Ref<'_, Chunk> { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/backend/objects.rs:58:29 [INFO] [stdout] | [INFO] [stdout] 58 | pub fn borrow_chunk_mut(&mut self) -> RefMut { [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 58 | pub fn borrow_chunk_mut(&mut self) -> RefMut<'_, Chunk> { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/backend/objects.rs:150:23 [INFO] [stdout] | [INFO] [stdout] 150 | pub fn borrow_fun(&self) -> Ref { [INFO] [stdout] | ^^^^^ ^^^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 150 | pub fn borrow_fun(&self) -> Ref<'_, FunData> { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/backend/objects.rs:154:27 [INFO] [stdout] | [INFO] [stdout] 154 | pub fn borrow_fun_mut(&mut self) -> RefMut { [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 154 | pub fn borrow_fun_mut(&mut self) -> RefMut<'_, FunData> { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/backend/native.rs:29:29 [INFO] [stdout] | [INFO] [stdout] 29 | Ok(Value::Str(s1.concat(&s2))) [INFO] [stdout] | ^^^ help: change this to: `s2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/frontend/scanner.rs:15:24 [INFO] [stdout] | [INFO] [stdout] 15 | pub fn new(source: &str) -> Scanner { [INFO] [stdout] | ^^^^ ^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] = note: `#[warn(mismatched_lifetime_syntaxes)]` on by default [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 15 | pub fn new(source: &str) -> Scanner<'_> { [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's named elsewhere is confusing [INFO] [stdout] --> src/frontend/compiler.rs:36:36 [INFO] [stdout] | [INFO] [stdout] 36 | pub fn new(source: &'a str) -> Compiler { [INFO] [stdout] | -- ^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is named here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: consistently use `'a` [INFO] [stdout] | [INFO] [stdout] 36 | pub fn new(source: &'a str) -> Compiler<'a> { [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/backend/chunk.rs:334:35 [INFO] [stdout] | [INFO] [stdout] 334 | pub fn instruction_iter(self: &Chunk) -> InstructionIter { [INFO] [stdout] | ^^^^^^ ^^^^^^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 334 | pub fn instruction_iter(self: &Chunk) -> InstructionIter<'_> { [INFO] [stdout] | ++++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/backend/vm.rs:62:20 [INFO] [stdout] | [INFO] [stdout] 62 | fn current_fun(&self) -> Ref { [INFO] [stdout] | ^^^^^ ^^^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 62 | fn current_fun(&self) -> Ref<'_, FunData> { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/backend/vm.rs:67:24 [INFO] [stdout] | [INFO] [stdout] 67 | fn current_fun_mut(&mut self) -> RefMut { [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 67 | fn current_fun_mut(&mut self) -> RefMut<'_, FunData> { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/backend/objects.rs:54:25 [INFO] [stdout] | [INFO] [stdout] 54 | pub fn borrow_chunk(&self) -> Ref { [INFO] [stdout] | ^^^^^ ^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 54 | pub fn borrow_chunk(&self) -> Ref<'_, Chunk> { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/backend/objects.rs:58:29 [INFO] [stdout] | [INFO] [stdout] 58 | pub fn borrow_chunk_mut(&mut self) -> RefMut { [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 58 | pub fn borrow_chunk_mut(&mut self) -> RefMut<'_, Chunk> { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/backend/objects.rs:150:23 [INFO] [stdout] | [INFO] [stdout] 150 | pub fn borrow_fun(&self) -> Ref { [INFO] [stdout] | ^^^^^ ^^^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 150 | pub fn borrow_fun(&self) -> Ref<'_, FunData> { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/backend/objects.rs:154:27 [INFO] [stdout] | [INFO] [stdout] 154 | pub fn borrow_fun_mut(&mut self) -> RefMut { [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 154 | pub fn borrow_fun_mut(&mut self) -> RefMut<'_, FunData> { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: empty string literal in `println!` [INFO] [stdout] --> tests/compiler_test.rs:229:5 [INFO] [stdout] | [INFO] [stdout] 229 | println!(""); [INFO] [stdout] | ^^^^^^^^^--^ [INFO] [stdout] | | [INFO] [stdout] | help: remove the empty string [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#println_empty_string [INFO] [stdout] = note: `#[warn(clippy::println_empty_string)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this assertion is always `false` [INFO] [stdout] --> tests/compiler_test.rs:240:14 [INFO] [stdout] | [INFO] [stdout] 240 | _ => assert!(false) [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: replace this with `panic!()` or `unreachable!()` [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assertions_on_constants [INFO] [stdout] = note: `#[warn(clippy::assertions_on_constants)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> tests/compiler_test.rs:263:21 [INFO] [stdout] | [INFO] [stdout] 263 | disassemble(&chunk,name); [INFO] [stdout] | ^^^^^^ help: change this to: `chunk` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 1.01s [INFO] running `Command { std: "docker" "inspect" "0f9bd95f5cd51cd45e59afca5c78f318152319048de7e9758925521aba7b00ff", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "0f9bd95f5cd51cd45e59afca5c78f318152319048de7e9758925521aba7b00ff", kill_on_drop: false }` [INFO] [stdout] 0f9bd95f5cd51cd45e59afca5c78f318152319048de7e9758925521aba7b00ff