[INFO] cloning repository https://github.com/TilenRupar/rust_neural_net [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/TilenRupar/rust_neural_net" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FTilenRupar%2Frust_neural_net", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FTilenRupar%2Frust_neural_net'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] d43906ddaba5c02850b1042803b5c4dd5cdd21c5 [INFO] linting TilenRupar/rust_neural_net against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FTilenRupar%2Frust_neural_net" "/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/TilenRupar/rust_neural_net [INFO] finished tweaking git repo https://github.com/TilenRupar/rust_neural_net [INFO] tweaked toml for git repo https://github.com/TilenRupar/rust_neural_net written to /workspace/builds/worker-2-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/TilenRupar/rust_neural_net 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/TilenRupar/rust_neural_net 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] Updating crates.io index [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded value-bag v1.9.0 [INFO] [stderr] Downloaded ta v0.5.0 [INFO] [stderr] Downloaded sqlx-macros v0.8.2 [INFO] [stderr] Downloaded dwrote v0.11.1 [INFO] [stderr] Downloaded async-executor v1.13.0 [INFO] [stderr] Downloaded pathfinder_simd v0.5.4 [INFO] [stderr] Downloaded unicode-properties v0.1.2 [INFO] [stderr] Downloaded font-kit v0.14.2 [INFO] [stderr] Downloaded sqlx-mysql v0.8.2 [INFO] [stderr] Downloaded flate2 v1.0.33 [INFO] [stderr] Downloaded sqlx-postgres v0.8.2 [INFO] [stderr] Downloaded sqlx-core v0.8.2 [INFO] [stderr] Downloaded rsa v0.9.6 [INFO] [stderr] Downloaded sqlx-macros-core v0.8.2 [INFO] [stderr] Downloaded sqlx v0.8.2 [INFO] [stderr] Downloaded sqlx-sqlite v0.8.2 [INFO] [stderr] Downloaded rustix v0.37.27 [INFO] [stderr] Downloaded rustix v0.38.36 [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] 425e1956208a246cfbdd5a25587e848d4da21d94516ab640f7913823f00c8456 [INFO] running `Command { std: "docker" "start" "-a" "425e1956208a246cfbdd5a25587e848d4da21d94516ab640f7913823f00c8456", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "425e1956208a246cfbdd5a25587e848d4da21d94516ab640f7913823f00c8456", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "425e1956208a246cfbdd5a25587e848d4da21d94516ab640f7913823f00c8456", kill_on_drop: false }` [INFO] [stdout] 425e1956208a246cfbdd5a25587e848d4da21d94516ab640f7913823f00c8456 [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] de67f687e5a3d12c4809388225097afebb62bdc1fb4ad8cb4bce980707058d0d [INFO] running `Command { std: "docker" "start" "-a" "de67f687e5a3d12c4809388225097afebb62bdc1fb4ad8cb4bce980707058d0d", kill_on_drop: false }` [INFO] [stderr] Compiling libc v0.2.158 [INFO] [stderr] Compiling pin-project-lite v0.2.14 [INFO] [stderr] Compiling futures-core v0.3.30 [INFO] [stderr] Compiling lock_api v0.4.12 [INFO] [stderr] Compiling serde v1.0.210 [INFO] [stderr] Compiling pkg-config v0.3.30 [INFO] [stderr] Compiling futures-io v0.3.30 [INFO] [stderr] Compiling crossbeam-utils v0.8.20 [INFO] [stderr] Compiling io-lifetimes v1.0.11 [INFO] [stderr] Compiling cc v1.1.16 [INFO] [stderr] Compiling quote v1.0.37 [INFO] [stderr] Checking value-bag v1.9.0 [INFO] [stderr] Checking concurrent-queue v2.5.0 [INFO] [stderr] Compiling polling v2.8.0 [INFO] [stderr] Compiling rustix v0.37.27 [INFO] [stderr] Compiling fastrand v2.1.1 [INFO] [stderr] Compiling slab v0.4.9 [INFO] [stderr] Compiling async-io v1.13.0 [INFO] [stderr] Compiling rustix v0.38.36 [INFO] [stderr] Compiling linux-raw-sys v0.4.14 [INFO] [stderr] Compiling bitflags v2.6.0 [INFO] [stderr] Compiling syn v2.0.77 [INFO] [stderr] Compiling log v0.4.22 [INFO] [stderr] Compiling futures-lite v2.3.0 [INFO] [stderr] Checking event-listener v5.3.1 [INFO] [stderr] Compiling tracing-core v0.1.32 [INFO] [stderr] Compiling num-traits v0.2.19 [INFO] [stderr] Compiling serde_json v1.0.128 [INFO] [stderr] Checking event-listener-strategy v0.5.2 [INFO] [stderr] Compiling generic-array v0.14.7 [INFO] [stderr] Compiling futures-sink v0.3.30 [INFO] [stderr] Compiling atomic-waker v1.1.2 [INFO] [stderr] Compiling zerocopy v0.7.35 [INFO] [stderr] Compiling async-task v4.7.1 [INFO] [stderr] Compiling tinyvec v1.8.0 [INFO] [stderr] Compiling piper v0.2.4 [INFO] [stderr] Compiling smallvec v1.13.2 [INFO] [stderr] Compiling linux-raw-sys v0.3.8 [INFO] [stderr] Compiling waker-fn v1.2.0 [INFO] [stderr] Compiling allocator-api2 v0.2.18 [INFO] [stderr] Compiling bitflags v1.3.2 [INFO] [stderr] Compiling fastrand v1.9.0 [INFO] [stderr] Compiling parking_lot_core v0.9.10 [INFO] [stderr] Compiling async-channel v2.3.1 [INFO] [stderr] Compiling ahash v0.8.11 [INFO] [stderr] Compiling async-lock v3.4.0 [INFO] [stderr] Compiling futures-lite v1.13.0 [INFO] [stderr] Compiling form_urlencoded v1.2.1 [INFO] [stderr] Compiling libsqlite3-sys v0.30.1 [INFO] [stderr] Compiling blocking v1.6.1 [INFO] [stderr] Compiling unicode-normalization v0.1.23 [INFO] [stderr] Compiling async-executor v1.13.0 [INFO] [stderr] Compiling hashbrown v0.14.5 [INFO] [stderr] Compiling async-lock v2.8.0 [INFO] [stderr] Compiling block-buffer v0.10.4 [INFO] [stderr] Compiling crypto-common v0.1.6 [INFO] [stderr] Compiling socket2 v0.4.10 [INFO] [stderr] Compiling futures-task v0.3.30 [INFO] [stderr] Compiling unicode-bidi v0.3.15 [INFO] [stderr] Compiling nom v7.1.3 [INFO] [stderr] Compiling futures-util v0.3.30 [INFO] [stderr] Compiling digest v0.10.7 [INFO] [stderr] Compiling rustc_version v0.4.1 [INFO] [stderr] Compiling parking_lot v0.12.3 [INFO] [stderr] Compiling idna v0.5.0 [INFO] [stderr] Compiling async-channel v1.9.0 [INFO] [stderr] Compiling kv-log-macro v1.0.7 [INFO] [stderr] Compiling iana-time-zone v0.1.60 [INFO] [stderr] Compiling cpufeatures v0.2.14 [INFO] [stderr] Compiling chrono v0.4.38 [INFO] [stderr] Compiling sha2 v0.10.8 [INFO] [stderr] Checking miniz_oxide v0.8.0 [INFO] [stderr] Compiling url v2.5.2 [INFO] [stderr] Compiling crc v3.2.1 [INFO] [stderr] Compiling indexmap v2.5.0 [INFO] [stderr] Compiling pathfinder_simd v0.5.4 [INFO] [stderr] Compiling futures-intrusive v0.5.0 [INFO] [stderr] Compiling hashlink v0.9.1 [INFO] [stderr] Compiling atoi v2.0.0 [INFO] [stderr] Compiling freetype-sys v0.20.1 [INFO] [stderr] Compiling sqlformat v0.2.6 [INFO] [stderr] Compiling futures-channel v0.3.30 [INFO] [stderr] Compiling spin v0.9.8 [INFO] [stderr] Compiling crossbeam-queue v0.3.11 [INFO] [stderr] Compiling yeslogic-fontconfig-sys v6.0.0 [INFO] [stderr] Compiling bytes v1.7.1 [INFO] [stderr] Checking miniz_oxide v0.7.4 [INFO] [stderr] Checking flate2 v1.0.33 [INFO] [stderr] Compiling flume v0.11.0 [INFO] [stderr] Checking fdeflate v0.3.4 [INFO] [stderr] Checking dirs-sys v0.4.1 [INFO] [stderr] Checking png v0.17.13 [INFO] [stderr] Compiling futures-executor v0.3.30 [INFO] [stderr] Checking bytemuck v1.18.0 [INFO] [stderr] Compiling font-kit v0.14.2 [INFO] [stderr] Checking pathfinder_geometry v0.5.1 [INFO] [stderr] Checking gif v0.12.0 [INFO] [stderr] Checking dirs v5.0.1 [INFO] [stderr] Checking float-ord v0.3.2 [INFO] [stderr] Checking mio v1.0.2 [INFO] [stderr] Checking socket2 v0.5.7 [INFO] [stderr] Checking signal-hook-registry v1.4.2 [INFO] [stderr] Checking ttf-parser v0.20.0 [INFO] [stderr] Checking ta v0.5.0 [INFO] [stderr] Checking image v0.24.9 [INFO] [stderr] Compiling tempfile v3.12.0 [INFO] [stderr] Compiling serde_derive v1.0.210 [INFO] [stderr] Compiling tracing-attributes v0.1.27 [INFO] [stderr] Compiling thiserror-impl v1.0.63 [INFO] [stderr] Compiling tokio-macros v2.4.0 [INFO] [stderr] Checking tokio v1.40.0 [INFO] [stderr] Compiling thiserror v1.0.63 [INFO] [stderr] Compiling tracing v0.1.40 [INFO] [stderr] Checking polling v3.7.3 [INFO] [stderr] Checking async-io v2.3.4 [INFO] [stderr] Checking plotters-bitmap v0.3.7 [INFO] [stderr] Checking async-global-executor v2.4.1 [INFO] [stderr] Checking async-std v1.12.0 [INFO] [stderr] Checking either v1.13.0 [INFO] [stderr] Checking serde_urlencoded v0.7.1 [INFO] [stderr] Checking itertools v0.13.0 [INFO] [stderr] Checking sqlx-core v0.8.2 [INFO] [stderr] Checking plotters v0.3.7 [INFO] [stderr] Checking sqlx-sqlite v0.8.2 [INFO] [stderr] Compiling sqlx-macros-core v0.8.2 [INFO] [stderr] Compiling sqlx-macros v0.8.2 [INFO] [stderr] Checking sqlx v0.8.2 [INFO] [stderr] Checking rust_neural_net v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: equality checks against false can be replaced by a negation [INFO] [stdout] --> src/load_candle.rs:20:8 [INFO] [stdout] | [INFO] [stdout] 20 | if Path::new(database_path).exists() == false { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `!Path::new(database_path).exists()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_comparison [INFO] [stdout] = note: `#[warn(clippy::bool_comparison)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: equality checks against false can be replaced by a negation [INFO] [stdout] --> src/load_candle.rs:20:8 [INFO] [stdout] | [INFO] [stdout] 20 | if Path::new(database_path).exists() == false { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `!Path::new(database_path).exists()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_comparison [INFO] [stdout] = note: `#[warn(clippy::bool_comparison)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/load_candle.rs:58:38 [INFO] [stdout] | [INFO] [stdout] 58 | pub fn get_candle_vector(candles: &Vec, field_selector: F) -> Vec [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] = note: `#[warn(clippy::ptr_arg)]` on by default [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 58 - pub fn get_candle_vector(candles: &Vec, field_selector: F) -> Vec [INFO] [stdout] 58 + pub fn get_candle_vector(candles: &[Candle], field_selector: F) -> Vec [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> src/load_candle.rs:62:24 [INFO] [stdout] | [INFO] [stdout] 62 | candles.iter().map(|candle| field_selector(candle)).collect() [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `field_selector` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] = note: `#[warn(clippy::redundant_closure)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: file opened with `create`, but `truncate` behavior not defined [INFO] [stdout] --> src/plot_candles.rs:11:42 [INFO] [stdout] | [INFO] [stdout] 11 | match OpenOptions::new().write(true).create(true).open(path) { [INFO] [stdout] | ^^^^^^^^^^^^- help: add: `.truncate(true)` [INFO] [stdout] | [INFO] [stdout] = help: if you intend to overwrite an existing file entirely, call `.truncate(true)` [INFO] [stdout] = help: if you instead know that you may want to keep some parts of the old file, call `.truncate(false)` [INFO] [stdout] = help: alternatively, use `.append(true)` to append to the file instead of overwriting it [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#suspicious_open_options [INFO] [stdout] = note: `#[warn(clippy::suspicious_open_options)]` 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/plot_candles.rs:41:52 [INFO] [stdout] | [INFO] [stdout] 41 | let close_prices: Vec = get_candle_vector(&candles, |candle| candle.close); [INFO] [stdout] | ^^^^^^^^ help: change this to: `candles` [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: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/load_candle.rs:58:38 [INFO] [stdout] | [INFO] [stdout] 58 | pub fn get_candle_vector(candles: &Vec, field_selector: F) -> Vec [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] = note: `#[warn(clippy::ptr_arg)]` on by default [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 58 - pub fn get_candle_vector(candles: &Vec, field_selector: F) -> Vec [INFO] [stdout] 58 + pub fn get_candle_vector(candles: &[Candle], field_selector: F) -> Vec [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> src/load_candle.rs:62:24 [INFO] [stdout] | [INFO] [stdout] 62 | candles.iter().map(|candle| field_selector(candle)).collect() [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `field_selector` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] = note: `#[warn(clippy::redundant_closure)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: explicit call to `.into_iter()` in function argument accepting `IntoIterator` [INFO] [stdout] --> src/ta.rs:20:32 [INFO] [stdout] | [INFO] [stdout] 20 | sma_values.into_iter().zip(ema_values.into_iter()).collect() [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()` [INFO] [stdout] --> /rustc/3645249d79dfb136b5d8de3ce153d19d6698d92d/library/core/src/iter/traits/iterator.rs:629:11 [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] = note: `#[warn(clippy::useless_conversion)]` on by default [INFO] [stdout] help: consider removing the `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 20 - sma_values.into_iter().zip(ema_values.into_iter()).collect() [INFO] [stdout] 20 + sma_values.into_iter().zip(ema_values).collect() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: file opened with `create`, but `truncate` behavior not defined [INFO] [stdout] --> src/plot_candles.rs:11:42 [INFO] [stdout] | [INFO] [stdout] 11 | match OpenOptions::new().write(true).create(true).open(path) { [INFO] [stdout] | ^^^^^^^^^^^^- help: add: `.truncate(true)` [INFO] [stdout] | [INFO] [stdout] = help: if you intend to overwrite an existing file entirely, call `.truncate(true)` [INFO] [stdout] = help: if you instead know that you may want to keep some parts of the old file, call `.truncate(false)` [INFO] [stdout] = help: alternatively, use `.append(true)` to append to the file instead of overwriting it [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#suspicious_open_options [INFO] [stdout] = note: `#[warn(clippy::suspicious_open_options)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/main.rs:10:28 [INFO] [stdout] | [INFO] [stdout] 10 | fn find_local_extrema(vec: &Vec, window_size: usize, minima: bool) -> Vec { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 10 - fn find_local_extrema(vec: &Vec, window_size: usize, minima: bool) -> Vec { [INFO] [stdout] 10 + fn find_local_extrema(vec: &[f64], window_size: usize, minima: bool) -> Vec { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual arithmetic check found [INFO] [stdout] --> src/main.rs:15:21 [INFO] [stdout] | [INFO] [stdout] 15 | let start = if i >= window_size { i - window_size } else { 0 }; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `i.saturating_sub(window_size)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implicit_saturating_sub [INFO] [stdout] = note: `#[warn(clippy::implicit_saturating_sub)]` 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/plot_candles.rs:41:52 [INFO] [stdout] | [INFO] [stdout] 41 | let close_prices: Vec = get_candle_vector(&candles, |candle| candle.close); [INFO] [stdout] | ^^^^^^^^ help: change this to: `candles` [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: explicit call to `.into_iter()` in function argument accepting `IntoIterator` [INFO] [stdout] --> src/ta.rs:20:32 [INFO] [stdout] | [INFO] [stdout] 20 | sma_values.into_iter().zip(ema_values.into_iter()).collect() [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()` [INFO] [stdout] --> /rustc/3645249d79dfb136b5d8de3ce153d19d6698d92d/library/core/src/iter/traits/iterator.rs:629:11 [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] = note: `#[warn(clippy::useless_conversion)]` on by default [INFO] [stdout] help: consider removing the `.into_iter()` [INFO] [stdout] | [INFO] [stdout] 20 - sma_values.into_iter().zip(ema_values.into_iter()).collect() [INFO] [stdout] 20 + sma_values.into_iter().zip(ema_values).collect() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/main.rs:10:28 [INFO] [stdout] | [INFO] [stdout] 10 | fn find_local_extrema(vec: &Vec, window_size: usize, minima: bool) -> Vec { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 10 - fn find_local_extrema(vec: &Vec, window_size: usize, minima: bool) -> Vec { [INFO] [stdout] 10 + fn find_local_extrema(vec: &[f64], window_size: usize, minima: bool) -> Vec { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual arithmetic check found [INFO] [stdout] --> src/main.rs:15:21 [INFO] [stdout] | [INFO] [stdout] 15 | let start = if i >= window_size { i - window_size } else { 0 }; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `i.saturating_sub(window_size)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implicit_saturating_sub [INFO] [stdout] = note: `#[warn(clippy::implicit_saturating_sub)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 52.43s [INFO] running `Command { std: "docker" "inspect" "de67f687e5a3d12c4809388225097afebb62bdc1fb4ad8cb4bce980707058d0d", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "de67f687e5a3d12c4809388225097afebb62bdc1fb4ad8cb4bce980707058d0d", kill_on_drop: false }` [INFO] [stdout] de67f687e5a3d12c4809388225097afebb62bdc1fb4ad8cb4bce980707058d0d