[INFO] updating cached repository hsabouri/42_ft_linear_regression [INFO] running `"git" "fetch" "--all"` [INFO] [stdout] Fetching origin [INFO] [stderr] From git://github.com/hsabouri/42_ft_linear_regression [INFO] [stderr] * branch HEAD -> FETCH_HEAD [INFO] running `"git" "clone" "work/cache/sources/gh/hsabouri/42_ft_linear_regression" "work/ex/clippy-test-run/sources/stable/gh/hsabouri/42_ft_linear_regression"` [INFO] [stderr] Cloning into 'work/ex/clippy-test-run/sources/stable/gh/hsabouri/42_ft_linear_regression'... [INFO] [stderr] done. [INFO] running `"git" "clone" "work/cache/sources/gh/hsabouri/42_ft_linear_regression" "work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/gh/hsabouri/42_ft_linear_regression"` [INFO] [stderr] Cloning into 'work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/gh/hsabouri/42_ft_linear_regression'... [INFO] [stderr] done. [INFO] running `"git" "rev-parse" "HEAD"` [INFO] [stdout] 6b0d7f632dc1e2041cd604dd43df83c1a8d6a9d5 [INFO] sha for GitHub repo hsabouri/42_ft_linear_regression: 6b0d7f632dc1e2041cd604dd43df83c1a8d6a9d5 [INFO] validating manifest of hsabouri/42_ft_linear_regression on toolchain stable [INFO] running `"/mnt/big/crater/work/local/cargo-home/bin/cargo" "+stable" "read-manifest" "--manifest-path" "Cargo.toml"` [INFO] validating manifest of hsabouri/42_ft_linear_regression on toolchain stable+rustflags=-Dclippy::into_iter_on_array [INFO] running `"/mnt/big/crater/work/local/cargo-home/bin/cargo" "+stable" "read-manifest" "--manifest-path" "Cargo.toml"` [INFO] started frobbing hsabouri/42_ft_linear_regression [INFO] finished frobbing hsabouri/42_ft_linear_regression [INFO] frobbed toml for hsabouri/42_ft_linear_regression written to work/ex/clippy-test-run/sources/stable/gh/hsabouri/42_ft_linear_regression/Cargo.toml [INFO] started frobbing hsabouri/42_ft_linear_regression [INFO] finished frobbing hsabouri/42_ft_linear_regression [INFO] frobbed toml for hsabouri/42_ft_linear_regression written to work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/gh/hsabouri/42_ft_linear_regression/Cargo.toml [INFO] crate hsabouri/42_ft_linear_regression has a lockfile. skipping [INFO] running `"/mnt/big/crater/work/local/cargo-home/bin/cargo" "+stable" "fetch" "--locked" "--manifest-path" "Cargo.toml"` [INFO] running `"/mnt/big/crater/work/local/cargo-home/bin/cargo" "+stable" "fetch" "--locked" "--manifest-path" "Cargo.toml"` [INFO] linting hsabouri/42_ft_linear_regression against stable for clippy-test-run [INFO] running `"docker" "create" "-v" "/mnt/big/crater/work/local/target-dirs/clippy-test-run/worker-0/stable:/opt/crater/target:rw,Z" "-v" "/mnt/big/crater/work/ex/clippy-test-run/sources/stable/gh/hsabouri/42_ft_linear_regression:/opt/crater/workdir:ro,Z" "-v" "/mnt/big/crater/work/local/cargo-home:/opt/crater/cargo-home:ro,Z" "-v" "/mnt/big/crater/work/local/rustup-home:/opt/crater/rustup-home:ro,Z" "-e" "USER_ID=1000" "-e" "SOURCE_DIR=/opt/crater/workdir" "-e" "MAP_USER_ID=1000" "-e" "CARGO_TARGET_DIR=/opt/crater/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/crater/cargo-home" "-e" "RUSTUP_HOME=/opt/crater/rustup-home" "-w" "/opt/crater/workdir" "-m" "1536M" "--network" "none" "rustops/crates-build-env" "/opt/crater/cargo-home/bin/cargo" "+stable" "clippy" "--frozen" "--all" "--all-targets"` [INFO] [stdout] 52c413120d3f234078ec6859ac233d31ad845ab8576487bbb10412985bbbe7b2 [INFO] running `"docker" "start" "-a" "52c413120d3f234078ec6859ac233d31ad845ab8576487bbb10412985bbbe7b2"` [INFO] [stderr] Compiling serde v1.0.58 [INFO] [stderr] Checking gnuplot v0.0.25 [INFO] [stderr] Checking memchr v2.0.1 [INFO] [stderr] Checking csv-core v0.1.4 [INFO] [stderr] Checking csv v1.0.0 [INFO] [stderr] Checking ft_linear_regression v0.1.0 (/opt/crater/workdir) [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/train.rs:58:13 [INFO] [stderr] | [INFO] [stderr] 58 | data: data, [INFO] [stderr] | ^^^^^^^^^^ help: replace it with: `data` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::redundant_field_names)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/train.rs:59:13 [INFO] [stderr] | [INFO] [stderr] 59 | min: min, [INFO] [stderr] | ^^^^^^^^ help: replace it with: `min` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/train.rs:60:13 [INFO] [stderr] | [INFO] [stderr] 60 | max: max, [INFO] [stderr] | ^^^^^^^^ help: replace it with: `max` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/train.rs:61:13 [INFO] [stderr] | [INFO] [stderr] 61 | x_min: x_min, [INFO] [stderr] | ^^^^^^^^^^^^ help: replace it with: `x_min` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/train.rs:62:13 [INFO] [stderr] | [INFO] [stderr] 62 | x_max: x_max, [INFO] [stderr] | ^^^^^^^^^^^^ help: replace it with: `x_max` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/train.rs:65:13 [INFO] [stderr] | [INFO] [stderr] 65 | learning_rate: learning_rate, [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `learning_rate` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/train.rs:66:13 [INFO] [stderr] | [INFO] [stderr] 66 | iterations: iterations [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `iterations` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/predict.rs:12:13 [INFO] [stderr] | [INFO] [stderr] 12 | theta: theta [INFO] [stderr] | ^^^^^^^^^^^^ help: replace it with: `theta` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/train.rs:58:13 [INFO] [stderr] | [INFO] [stderr] 58 | data: data, [INFO] [stderr] | ^^^^^^^^^^ help: replace it with: `data` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::redundant_field_names)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/train.rs:59:13 [INFO] [stderr] | [INFO] [stderr] 59 | min: min, [INFO] [stderr] | ^^^^^^^^ help: replace it with: `min` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/train.rs:60:13 [INFO] [stderr] | [INFO] [stderr] 60 | max: max, [INFO] [stderr] | ^^^^^^^^ help: replace it with: `max` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/train.rs:61:13 [INFO] [stderr] | [INFO] [stderr] 61 | x_min: x_min, [INFO] [stderr] | ^^^^^^^^^^^^ help: replace it with: `x_min` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/train.rs:62:13 [INFO] [stderr] | [INFO] [stderr] 62 | x_max: x_max, [INFO] [stderr] | ^^^^^^^^^^^^ help: replace it with: `x_max` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/train.rs:65:13 [INFO] [stderr] | [INFO] [stderr] 65 | learning_rate: learning_rate, [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `learning_rate` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/train.rs:66:13 [INFO] [stderr] | [INFO] [stderr] 66 | iterations: iterations [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `iterations` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/predict.rs:12:13 [INFO] [stderr] | [INFO] [stderr] 12 | theta: theta [INFO] [stderr] | ^^^^^^^^^^^^ help: replace it with: `theta` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names [INFO] [stderr] [INFO] [stderr] warning: unused import: `std::fmt` [INFO] [stderr] --> src/predict.rs:2:5 [INFO] [stderr] | [INFO] [stderr] 2 | use std::fmt; [INFO] [stderr] | ^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(unused_imports)] on by default [INFO] [stderr] [INFO] [stderr] warning: unused import: `std::fmt` [INFO] [stderr] --> src/predict.rs:2:5 [INFO] [stderr] | [INFO] [stderr] 2 | use std::fmt; [INFO] [stderr] | ^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(unused_imports)] on by default [INFO] [stderr] [INFO] [stderr] warning: writing `&Vec<_>` instead of `&[_]` involves one more reference and cannot be used with non-Vec-based slices. [INFO] [stderr] --> src/predict.rs:16:32 [INFO] [stderr] | [INFO] [stderr] 16 | fn predict(&self, dataset: &Vec) -> Vec { [INFO] [stderr] | ^^^^^^^^^ help: change this to: `&[f32]` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::ptr_arg)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stderr] [INFO] [stderr] warning: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` [INFO] [stderr] --> src/main.rs:53:9 [INFO] [stderr] | [INFO] [stderr] 53 | / match sub_predict(matches) { [INFO] [stderr] 54 | | Err(error) => { [INFO] [stderr] 55 | | println!("{}", error); [INFO] [stderr] 56 | | }, [INFO] [stderr] 57 | | _ => {} [INFO] [stderr] 58 | | } [INFO] [stderr] | |_________^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::single_match)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match [INFO] [stderr] help: try this [INFO] [stderr] | [INFO] [stderr] 53 | if let Err(error) = sub_predict(matches) { [INFO] [stderr] 54 | println!("{}", error); [INFO] [stderr] 55 | } [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: writing `&Vec<_>` instead of `&[_]` involves one more reference and cannot be used with non-Vec-based slices. [INFO] [stderr] --> src/predict.rs:16:32 [INFO] [stderr] | [INFO] [stderr] 16 | fn predict(&self, dataset: &Vec) -> Vec { [INFO] [stderr] | ^^^^^^^^^ help: change this to: `&[f32]` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::ptr_arg)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stderr] [INFO] [stderr] warning: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` [INFO] [stderr] --> src/main.rs:53:9 [INFO] [stderr] | [INFO] [stderr] 53 | / match sub_predict(matches) { [INFO] [stderr] 54 | | Err(error) => { [INFO] [stderr] 55 | | println!("{}", error); [INFO] [stderr] 56 | | }, [INFO] [stderr] 57 | | _ => {} [INFO] [stderr] 58 | | } [INFO] [stderr] | |_________^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::single_match)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match [INFO] [stderr] help: try this [INFO] [stderr] | [INFO] [stderr] 53 | if let Err(error) = sub_predict(matches) { [INFO] [stderr] 54 | println!("{}", error); [INFO] [stderr] 55 | } [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] Finished dev [unoptimized + debuginfo] target(s) in 13.89s [INFO] running `"docker" "inspect" "52c413120d3f234078ec6859ac233d31ad845ab8576487bbb10412985bbbe7b2"` [INFO] running `"docker" "rm" "-f" "52c413120d3f234078ec6859ac233d31ad845ab8576487bbb10412985bbbe7b2"` [INFO] [stdout] 52c413120d3f234078ec6859ac233d31ad845ab8576487bbb10412985bbbe7b2