[INFO] cloning repository https://github.com/afaber999/bang_rust [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/afaber999/bang_rust" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fafaber999%2Fbang_rust", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fafaber999%2Fbang_rust'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 8d5608e3de03c2e30896e12c3f5d4bd747d2c9d0 [INFO] linting afaber999/bang_rust against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fafaber999%2Fbang_rust" "/workspace/builds/worker-5-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-5-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/afaber999/bang_rust [INFO] finished tweaking git repo https://github.com/afaber999/bang_rust [INFO] tweaked toml for git repo https://github.com/afaber999/bang_rust written to /workspace/builds/worker-5-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/afaber999/bang_rust 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/afaber999/bang_rust 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] [stderr] Downloading crates ... [INFO] [stderr] Downloaded enum-iterator v0.6.0 [INFO] [stderr] Downloaded enum-iterator-derive v0.6.0 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-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] 17df7428971cecd4e432d70543e079bb88e3e8f146ed40d7754645b789bfc863 [INFO] running `Command { std: "docker" "start" "-a" "17df7428971cecd4e432d70543e079bb88e3e8f146ed40d7754645b789bfc863", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "17df7428971cecd4e432d70543e079bb88e3e8f146ed40d7754645b789bfc863", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "17df7428971cecd4e432d70543e079bb88e3e8f146ed40d7754645b789bfc863", kill_on_drop: false }` [INFO] [stdout] 17df7428971cecd4e432d70543e079bb88e3e8f146ed40d7754645b789bfc863 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-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] 061a63e657c73c21992db585ffbe520f922d5e84abc69ed1bc4518feeae24106 [INFO] running `Command { std: "docker" "start" "-a" "061a63e657c73c21992db585ffbe520f922d5e84abc69ed1bc4518feeae24106", kill_on_drop: false }` [INFO] [stderr] Compiling proc-macro2 v1.0.27 [INFO] [stderr] Compiling syn v1.0.72 [INFO] [stderr] Compiling quote v1.0.9 [INFO] [stderr] Compiling thiserror-impl v1.0.25 [INFO] [stderr] Compiling enum-iterator-derive v0.6.0 [INFO] [stderr] Compiling variant_count v1.1.0 [INFO] [stderr] Checking enum-iterator v0.6.0 [INFO] [stderr] Checking thiserror v1.0.25 [INFO] [stderr] Checking bang v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: variable `loc` is assigned to, but never used [INFO] [stdout] --> src/parser.rs:35:25 [INFO] [stdout] | [INFO] [stdout] 35 | let mut loc = token.loc; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: consider using `_loc` instead [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `loc` is assigned to, but never used [INFO] [stdout] --> src/parser.rs:50:29 [INFO] [stdout] | [INFO] [stdout] 50 | let mut loc = token.loc; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: consider using `_loc` instead [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `loc` is never read [INFO] [stdout] --> src/parser.rs:36:21 [INFO] [stdout] | [INFO] [stdout] 36 | loc.col += i + 1; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] = note: `#[warn(unused_assignments)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `loc` is never read [INFO] [stdout] --> src/parser.rs:51:25 [INFO] [stdout] | [INFO] [stdout] 51 | loc.col += i + 2; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: importing legacy numeric constants [INFO] [stdout] --> src/lexer.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use std::usize; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: remove this import [INFO] [stdout] = note: then `usize::` will resolve to the respective associated constant [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants [INFO] [stdout] = note: `#[warn(clippy::legacy_numeric_constants)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `loc` is assigned to, but never used [INFO] [stdout] --> src/parser.rs:35:25 [INFO] [stdout] | [INFO] [stdout] 35 | let mut loc = token.loc; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: consider using `_loc` instead [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `loc` is assigned to, but never used [INFO] [stdout] --> src/parser.rs:50:29 [INFO] [stdout] | [INFO] [stdout] 50 | let mut loc = token.loc; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: consider using `_loc` instead [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `loc` is never read [INFO] [stdout] --> src/parser.rs:36:21 [INFO] [stdout] | [INFO] [stdout] 36 | loc.col += i + 1; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] = note: `#[warn(unused_assignments)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `loc` is never read [INFO] [stdout] --> src/parser.rs:51:25 [INFO] [stdout] | [INFO] [stdout] 51 | loc.col += i + 2; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: use of `char::is_digit` with literal radix of 10 [INFO] [stdout] --> src/lexer.rs:148:9 [INFO] [stdout] | [INFO] [stdout] 148 | ch.is_digit(10) || ch == '.' [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: try: `ch.is_ascii_digit()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#is_digit_ascii_radix [INFO] [stdout] = note: `#[warn(clippy::is_digit_ascii_radix)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/parser.rs:553:34 [INFO] [stdout] | [INFO] [stdout] 553 | if self.lexer.is_keyword(&token, "proc") { [INFO] [stdout] | ^^^^^^ help: change this to: `token` [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: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/parser.rs:557:34 [INFO] [stdout] | [INFO] [stdout] 557 | if self.lexer.is_keyword(&token, "var") { [INFO] [stdout] | ^^^^^^ help: change this to: `token` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `Scope` [INFO] [stdout] --> src/basm_compiler.rs:90:5 [INFO] [stdout] | [INFO] [stdout] 90 | / pub fn new() -> Self { [INFO] [stdout] 91 | | Self { [INFO] [stdout] 92 | | vars: HashMap::new(), [INFO] [stdout] 93 | | } [INFO] [stdout] 94 | | } [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] 89 + impl Default for Scope { [INFO] [stdout] 90 + fn default() -> Self { [INFO] [stdout] 91 + Self::new() [INFO] [stdout] 92 + } [INFO] [stdout] 93 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `.is_multiple_of()` [INFO] [stdout] --> src/basm_compiler.rs:160:17 [INFO] [stdout] | [INFO] [stdout] 160 | assert!((self.program.len() % 2) == 0); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `self.program.len().is_multiple_of(2)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_is_multiple_of [INFO] [stdout] = note: `#[warn(clippy::manual_is_multiple_of)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: importing legacy numeric constants [INFO] [stdout] --> src/lexer.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use std::usize; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: remove this import [INFO] [stdout] = note: then `usize::` will resolve to the respective associated constant [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants [INFO] [stdout] = note: `#[warn(clippy::legacy_numeric_constants)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting to the same type is unnecessary (`i64` -> `i64`) [INFO] [stdout] --> src/basm_compiler.rs:325:32 [INFO] [stdout] | [INFO] [stdout] 325 | func_idx = *idx as i64; [INFO] [stdout] | ^^^^^^^^^^^ help: try: `*idx` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:330:47 [INFO] [stdout] | [INFO] [stdout] 330 | self.check_function_arity(&func_call, 1); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `func_call` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:410:35 [INFO] [stdout] | [INFO] [stdout] 410 | self.check_function_arity(&func_call, 1); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `func_call` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: use of `char::is_digit` with literal radix of 10 [INFO] [stdout] --> src/lexer.rs:148:9 [INFO] [stdout] | [INFO] [stdout] 148 | ch.is_digit(10) || ch == '.' [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: try: `ch.is_ascii_digit()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#is_digit_ascii_radix [INFO] [stdout] = note: `#[warn(clippy::is_digit_ascii_radix)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:479:35 [INFO] [stdout] | [INFO] [stdout] 479 | self.check_function_arity(&func_call, 2); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `func_call` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting to the same type is unnecessary (`i64` -> `i64`) [INFO] [stdout] --> src/basm_compiler.rs:494:28 [INFO] [stdout] | [INFO] [stdout] 494 | let func_idx = *idx as i64; [INFO] [stdout] | ^^^^^^^^^^^ help: try: `*idx` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/basm_compiler.rs:517:12 [INFO] [stdout] | [INFO] [stdout] 517 | if (from_type == AstTypes::I64 && to_type == AstTypes::PTR) [INFO] [stdout] | ____________^ [INFO] [stdout] 518 | | || (from_type == AstTypes::I64 && to_type == AstTypes::U8) [INFO] [stdout] | |______________________________________________________________________^ [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] help: try [INFO] [stdout] | [INFO] [stdout] 517 - if (from_type == AstTypes::I64 && to_type == AstTypes::PTR) [INFO] [stdout] 518 - || (from_type == AstTypes::I64 && to_type == AstTypes::U8) [INFO] [stdout] 517 + if !(from_type != AstTypes::I64 || to_type != AstTypes::PTR && to_type != AstTypes::U8) [INFO] [stdout] | [INFO] [stdout] 517 - if (from_type == AstTypes::I64 && to_type == AstTypes::PTR) [INFO] [stdout] 518 - || (from_type == AstTypes::I64 && to_type == AstTypes::U8) [INFO] [stdout] 517 + if (to_type == AstTypes::U8 || to_type == AstTypes::PTR) && from_type == AstTypes::I64 [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:508:35 [INFO] [stdout] | [INFO] [stdout] 508 | self.check_function_arity(&func_call, 2); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `func_call` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:537:35 [INFO] [stdout] | [INFO] [stdout] 537 | self.check_function_arity(&func_call, 2); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `func_call` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:554:35 [INFO] [stdout] | [INFO] [stdout] 554 | self.check_function_arity(&func_call, 3); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `func_call` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:602:54 [INFO] [stdout] | [INFO] [stdout] 602 | fmt_loc_err(self.filename_locations, &loc); [INFO] [stdout] | ^^^^ help: change this to: `loc` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:616:54 [INFO] [stdout] | [INFO] [stdout] 616 | fmt_loc_err(self.filename_locations, &loc); [INFO] [stdout] | ^^^^ help: change this to: `loc` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:658:32 [INFO] [stdout] | [INFO] [stdout] 658 | self.compile_block(&else_block); [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `else_block` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:758:55 [INFO] [stdout] | [INFO] [stdout] 758 | let compiled_expr = self.compile_expr(&expr); [INFO] [stdout] | ^^^^^ help: change this to: `expr` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:765:42 [INFO] [stdout] | [INFO] [stdout] 765 | self.compile_if_statment(&if_statement); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `if_statement` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:789:36 [INFO] [stdout] | [INFO] [stdout] 789 | self.compile_statement(&stmt) [INFO] [stdout] | ^^^^^ help: change this to: `stmt` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:825:28 [INFO] [stdout] | [INFO] [stdout] 825 | self.compile_block(&body); [INFO] [stdout] | ^^^^^ help: change this to: `body` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:853:49 [INFO] [stdout] | [INFO] [stdout] 853 | self.scope_get_compiled_var_by_name(&scope, &var_def.name) [INFO] [stdout] | ^^^^^^ help: change this to: `scope` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: returning the result of a `let` binding from a block [INFO] [stdout] --> src/basm_compiler.rs:897:17 [INFO] [stdout] | [INFO] [stdout] 892 | / let compiled_var = CompiledVar { [INFO] [stdout] 893 | | addr : addr as BMaddr, [INFO] [stdout] 894 | | storage, [INFO] [stdout] 895 | | def: var_def.clone(), [INFO] [stdout] 896 | | }; [INFO] [stdout] | |__________________- unnecessary `let` binding [INFO] [stdout] 897 | compiled_var [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] 892 ~ [INFO] [stdout] 893 ~ CompiledVar { [INFO] [stdout] 894 + addr : addr as BMaddr, [INFO] [stdout] 895 + storage, [INFO] [stdout] 896 + def: var_def.clone(), [INFO] [stdout] 897 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:912:59 [INFO] [stdout] | [INFO] [stdout] 912 | let compiled_expr = self.compile_expr(&init_expr); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `init_expr` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:954:43 [INFO] [stdout] | [INFO] [stdout] 954 | self.compile_proc_def(&proc_def); [INFO] [stdout] | ^^^^^^^^^ help: change this to: `proc_def` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:957:42 [INFO] [stdout] | [INFO] [stdout] 957 | self.compile_var_def(&var_def, VarStorageKind::Static); [INFO] [stdout] | ^^^^^^^^ help: change this to: `var_def` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:1175:29 [INFO] [stdout] | [INFO] [stdout] 1175 | self.compile_module(&module); [INFO] [stdout] | ^^^^^^^ help: change this to: `module` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/parser.rs:553:34 [INFO] [stdout] | [INFO] [stdout] 553 | if self.lexer.is_keyword(&token, "proc") { [INFO] [stdout] | ^^^^^^ help: change this to: `token` [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: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/parser.rs:557:34 [INFO] [stdout] | [INFO] [stdout] 557 | if self.lexer.is_keyword(&token, "var") { [INFO] [stdout] | ^^^^^^ help: change this to: `token` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `Scope` [INFO] [stdout] --> src/basm_compiler.rs:90:5 [INFO] [stdout] | [INFO] [stdout] 90 | / pub fn new() -> Self { [INFO] [stdout] 91 | | Self { [INFO] [stdout] 92 | | vars: HashMap::new(), [INFO] [stdout] 93 | | } [INFO] [stdout] 94 | | } [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] 89 + impl Default for Scope { [INFO] [stdout] 90 + fn default() -> Self { [INFO] [stdout] 91 + Self::new() [INFO] [stdout] 92 + } [INFO] [stdout] 93 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `.is_multiple_of()` [INFO] [stdout] --> src/basm_compiler.rs:160:17 [INFO] [stdout] | [INFO] [stdout] 160 | assert!((self.program.len() % 2) == 0); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `self.program.len().is_multiple_of(2)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_is_multiple_of [INFO] [stdout] = note: `#[warn(clippy::manual_is_multiple_of)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting to the same type is unnecessary (`i64` -> `i64`) [INFO] [stdout] --> src/basm_compiler.rs:325:32 [INFO] [stdout] | [INFO] [stdout] 325 | func_idx = *idx as i64; [INFO] [stdout] | ^^^^^^^^^^^ help: try: `*idx` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:330:47 [INFO] [stdout] | [INFO] [stdout] 330 | self.check_function_arity(&func_call, 1); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `func_call` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:410:35 [INFO] [stdout] | [INFO] [stdout] 410 | self.check_function_arity(&func_call, 1); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `func_call` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:479:35 [INFO] [stdout] | [INFO] [stdout] 479 | self.check_function_arity(&func_call, 2); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `func_call` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting to the same type is unnecessary (`i64` -> `i64`) [INFO] [stdout] --> src/basm_compiler.rs:494:28 [INFO] [stdout] | [INFO] [stdout] 494 | let func_idx = *idx as i64; [INFO] [stdout] | ^^^^^^^^^^^ help: try: `*idx` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/basm_compiler.rs:517:12 [INFO] [stdout] | [INFO] [stdout] 517 | if (from_type == AstTypes::I64 && to_type == AstTypes::PTR) [INFO] [stdout] | ____________^ [INFO] [stdout] 518 | | || (from_type == AstTypes::I64 && to_type == AstTypes::U8) [INFO] [stdout] | |______________________________________________________________________^ [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] help: try [INFO] [stdout] | [INFO] [stdout] 517 - if (from_type == AstTypes::I64 && to_type == AstTypes::PTR) [INFO] [stdout] 518 - || (from_type == AstTypes::I64 && to_type == AstTypes::U8) [INFO] [stdout] 517 + if !(from_type != AstTypes::I64 || to_type != AstTypes::PTR && to_type != AstTypes::U8) [INFO] [stdout] | [INFO] [stdout] 517 - if (from_type == AstTypes::I64 && to_type == AstTypes::PTR) [INFO] [stdout] 518 - || (from_type == AstTypes::I64 && to_type == AstTypes::U8) [INFO] [stdout] 517 + if (to_type == AstTypes::U8 || to_type == AstTypes::PTR) && from_type == AstTypes::I64 [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:508:35 [INFO] [stdout] | [INFO] [stdout] 508 | self.check_function_arity(&func_call, 2); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `func_call` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:537:35 [INFO] [stdout] | [INFO] [stdout] 537 | self.check_function_arity(&func_call, 2); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `func_call` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:554:35 [INFO] [stdout] | [INFO] [stdout] 554 | self.check_function_arity(&func_call, 3); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `func_call` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:602:54 [INFO] [stdout] | [INFO] [stdout] 602 | fmt_loc_err(self.filename_locations, &loc); [INFO] [stdout] | ^^^^ help: change this to: `loc` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:616:54 [INFO] [stdout] | [INFO] [stdout] 616 | fmt_loc_err(self.filename_locations, &loc); [INFO] [stdout] | ^^^^ help: change this to: `loc` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:658:32 [INFO] [stdout] | [INFO] [stdout] 658 | self.compile_block(&else_block); [INFO] [stdout] | ^^^^^^^^^^^ help: change this to: `else_block` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:758:55 [INFO] [stdout] | [INFO] [stdout] 758 | let compiled_expr = self.compile_expr(&expr); [INFO] [stdout] | ^^^^^ help: change this to: `expr` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:765:42 [INFO] [stdout] | [INFO] [stdout] 765 | self.compile_if_statment(&if_statement); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `if_statement` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:789:36 [INFO] [stdout] | [INFO] [stdout] 789 | self.compile_statement(&stmt) [INFO] [stdout] | ^^^^^ help: change this to: `stmt` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:825:28 [INFO] [stdout] | [INFO] [stdout] 825 | self.compile_block(&body); [INFO] [stdout] | ^^^^^ help: change this to: `body` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:853:49 [INFO] [stdout] | [INFO] [stdout] 853 | self.scope_get_compiled_var_by_name(&scope, &var_def.name) [INFO] [stdout] | ^^^^^^ help: change this to: `scope` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: returning the result of a `let` binding from a block [INFO] [stdout] --> src/basm_compiler.rs:897:17 [INFO] [stdout] | [INFO] [stdout] 892 | / let compiled_var = CompiledVar { [INFO] [stdout] 893 | | addr : addr as BMaddr, [INFO] [stdout] 894 | | storage, [INFO] [stdout] 895 | | def: var_def.clone(), [INFO] [stdout] 896 | | }; [INFO] [stdout] | |__________________- unnecessary `let` binding [INFO] [stdout] 897 | compiled_var [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] 892 ~ [INFO] [stdout] 893 ~ CompiledVar { [INFO] [stdout] 894 + addr : addr as BMaddr, [INFO] [stdout] 895 + storage, [INFO] [stdout] 896 + def: var_def.clone(), [INFO] [stdout] 897 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:912:59 [INFO] [stdout] | [INFO] [stdout] 912 | let compiled_expr = self.compile_expr(&init_expr); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `init_expr` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:954:43 [INFO] [stdout] | [INFO] [stdout] 954 | self.compile_proc_def(&proc_def); [INFO] [stdout] | ^^^^^^^^^ help: change this to: `proc_def` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:957:42 [INFO] [stdout] | [INFO] [stdout] 957 | self.compile_var_def(&var_def, VarStorageKind::Static); [INFO] [stdout] | ^^^^^^^^ help: change this to: `var_def` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/basm_compiler.rs:1175:29 [INFO] [stdout] | [INFO] [stdout] 1175 | self.compile_module(&module); [INFO] [stdout] | ^^^^^^^ help: change this to: `module` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variables can be used directly in the `format!` string [INFO] [stdout] --> src/main.rs:18:5 [INFO] [stdout] | [INFO] [stdout] 18 | println!("Usage: {} [OPTIONS] ", program_name); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args [INFO] [stdout] note: the lint level is defined here [INFO] [stdout] --> src/main.rs:4:9 [INFO] [stdout] | [INFO] [stdout] 4 | #![warn(clippy::pedantic)] [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] = note: `#[warn(clippy::uninlined_format_args)]` implied by `#[warn(clippy::pedantic)]` [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 18 - println!("Usage: {} [OPTIONS] ", program_name); [INFO] [stdout] 18 + println!("Usage: {program_name} [OPTIONS] "); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variables can be used directly in the `format!` string [INFO] [stdout] --> src/main.rs:28:13 [INFO] [stdout] | [INFO] [stdout] 28 | eprintln!("{:?}", s); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 28 - eprintln!("{:?}", s); [INFO] [stdout] 28 + eprintln!("{s:?}"); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: assigning the result of `Clone::clone()` may be inefficient [INFO] [stdout] --> src/main.rs:77:9 [INFO] [stdout] | [INFO] [stdout] 77 | output_file_path = input_file_path.clone(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `output_file_path.clone_from(&input_file_path)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones [INFO] [stdout] = note: `#[warn(clippy::assigning_clones)]` implied by `#[warn(clippy::pedantic)]` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary `Debug` formatting in `println!` args [INFO] [stdout] --> src/main.rs:81:39 [INFO] [stdout] | [INFO] [stdout] 81 | println!("Input filename : {:?}", input_file_path.as_os_str()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: use `Display` formatting and change this to `input_file_path.as_os_str().display()` [INFO] [stdout] = note: switching to `Display` formatting will change how the value is shown; escaped characters will no longer be escaped and surrounding quotes will be removed [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_debug_formatting [INFO] [stdout] = note: `#[warn(clippy::unnecessary_debug_formatting)]` implied by `#[warn(clippy::pedantic)]` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary `Debug` formatting in `println!` args [INFO] [stdout] --> src/main.rs:82:39 [INFO] [stdout] | [INFO] [stdout] 82 | println!("Output filename: {:?}", output_file_path.as_os_str()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: use `Display` formatting and change this to `output_file_path.as_os_str().display()` [INFO] [stdout] = note: switching to `Display` formatting will change how the value is shown; escaped characters will no longer be escaped and surrounding quotes will be removed [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_debug_formatting [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variables can be used directly in the `format!` string [INFO] [stdout] --> src/main.rs:86:5 [INFO] [stdout] | [INFO] [stdout] 86 | print!("{}", input_file); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 86 - print!("{}", input_file); [INFO] [stdout] 86 + print!("{input_file}"); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variables can be used directly in the `format!` string [INFO] [stdout] --> src/main.rs:18:5 [INFO] [stdout] | [INFO] [stdout] 18 | println!("Usage: {} [OPTIONS] ", program_name); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args [INFO] [stdout] note: the lint level is defined here [INFO] [stdout] --> src/main.rs:4:9 [INFO] [stdout] | [INFO] [stdout] 4 | #![warn(clippy::pedantic)] [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] = note: `#[warn(clippy::uninlined_format_args)]` implied by `#[warn(clippy::pedantic)]` [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 18 - println!("Usage: {} [OPTIONS] ", program_name); [INFO] [stdout] 18 + println!("Usage: {program_name} [OPTIONS] "); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variables can be used directly in the `format!` string [INFO] [stdout] --> src/main.rs:28:13 [INFO] [stdout] | [INFO] [stdout] 28 | eprintln!("{:?}", s); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 28 - eprintln!("{:?}", s); [INFO] [stdout] 28 + eprintln!("{s:?}"); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: assigning the result of `Clone::clone()` may be inefficient [INFO] [stdout] --> src/main.rs:77:9 [INFO] [stdout] | [INFO] [stdout] 77 | output_file_path = input_file_path.clone(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `output_file_path.clone_from(&input_file_path)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones [INFO] [stdout] = note: `#[warn(clippy::assigning_clones)]` implied by `#[warn(clippy::pedantic)]` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary `Debug` formatting in `println!` args [INFO] [stdout] --> src/main.rs:81:39 [INFO] [stdout] | [INFO] [stdout] 81 | println!("Input filename : {:?}", input_file_path.as_os_str()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: use `Display` formatting and change this to `input_file_path.as_os_str().display()` [INFO] [stdout] = note: switching to `Display` formatting will change how the value is shown; escaped characters will no longer be escaped and surrounding quotes will be removed [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_debug_formatting [INFO] [stdout] = note: `#[warn(clippy::unnecessary_debug_formatting)]` implied by `#[warn(clippy::pedantic)]` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary `Debug` formatting in `println!` args [INFO] [stdout] --> src/main.rs:82:39 [INFO] [stdout] | [INFO] [stdout] 82 | println!("Output filename: {:?}", output_file_path.as_os_str()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: use `Display` formatting and change this to `output_file_path.as_os_str().display()` [INFO] [stdout] = note: switching to `Display` formatting will change how the value is shown; escaped characters will no longer be escaped and surrounding quotes will be removed [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_debug_formatting [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variables can be used directly in the `format!` string [INFO] [stdout] --> src/main.rs:86:5 [INFO] [stdout] | [INFO] [stdout] 86 | print!("{}", input_file); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 86 - print!("{}", input_file); [INFO] [stdout] 86 + print!("{input_file}"); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 5.66s [INFO] running `Command { std: "docker" "inspect" "061a63e657c73c21992db585ffbe520f922d5e84abc69ed1bc4518feeae24106", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "061a63e657c73c21992db585ffbe520f922d5e84abc69ed1bc4518feeae24106", kill_on_drop: false }` [INFO] [stdout] 061a63e657c73c21992db585ffbe520f922d5e84abc69ed1bc4518feeae24106