[INFO] updating cached repository andschwa/rust-genetic-algorithm [INFO] running `"git" "fetch" "--all"` [INFO] [stdout] Fetching origin [INFO] [stderr] From git://github.com/andschwa/rust-genetic-algorithm [INFO] [stderr] * branch HEAD -> FETCH_HEAD [INFO] running `"git" "clone" "work/cache/sources/gh/andschwa/rust-genetic-algorithm" "work/ex/clippy-test-run/sources/stable/gh/andschwa/rust-genetic-algorithm"` [INFO] [stderr] Cloning into 'work/ex/clippy-test-run/sources/stable/gh/andschwa/rust-genetic-algorithm'... [INFO] [stderr] done. [INFO] running `"git" "clone" "work/cache/sources/gh/andschwa/rust-genetic-algorithm" "work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/gh/andschwa/rust-genetic-algorithm"` [INFO] [stderr] Cloning into 'work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/gh/andschwa/rust-genetic-algorithm'... [INFO] [stderr] done. [INFO] running `"git" "rev-parse" "HEAD"` [INFO] [stdout] a0477eecdab3f356a73ee4802279b6bd533b12f6 [INFO] sha for GitHub repo andschwa/rust-genetic-algorithm: a0477eecdab3f356a73ee4802279b6bd533b12f6 [INFO] validating manifest of andschwa/rust-genetic-algorithm 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 andschwa/rust-genetic-algorithm 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 andschwa/rust-genetic-algorithm [INFO] finished frobbing andschwa/rust-genetic-algorithm [INFO] frobbed toml for andschwa/rust-genetic-algorithm written to work/ex/clippy-test-run/sources/stable/gh/andschwa/rust-genetic-algorithm/Cargo.toml [INFO] started frobbing andschwa/rust-genetic-algorithm [INFO] finished frobbing andschwa/rust-genetic-algorithm [INFO] frobbed toml for andschwa/rust-genetic-algorithm written to work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/gh/andschwa/rust-genetic-algorithm/Cargo.toml [INFO] crate andschwa/rust-genetic-algorithm 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 andschwa/rust-genetic-algorithm against stable for clippy-test-run [INFO] running `"docker" "create" "-v" "/mnt/big/crater/work/local/target-dirs/clippy-test-run/worker-4/stable:/opt/crater/target:rw,Z" "-v" "/mnt/big/crater/work/ex/clippy-test-run/sources/stable/gh/andschwa/rust-genetic-algorithm:/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] 9cd8f45ebc9aa2c68b354a5ed4d768700eaed161516aac1c78de3f83e04825b6 [INFO] running `"docker" "start" "-a" "9cd8f45ebc9aa2c68b354a5ed4d768700eaed161516aac1c78de3f83e04825b6"` [INFO] [stderr] Checking ansi_term v0.11.0 [INFO] [stderr] Checking libc v0.2.38 [INFO] [stderr] Checking strsim v0.7.0 [INFO] [stderr] Checking clap v0.10.5 [INFO] [stderr] Checking rand v0.4.2 [INFO] [stderr] Checking time v0.1.39 [INFO] [stderr] Checking rust-genetic-algorithm v1.3.0 (/opt/crater/workdir) [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/algorithm.rs:64:21 [INFO] [stderr] | [INFO] [stderr] 64 | problem: problem, parameters: params, [INFO] [stderr] | ^^^^^^^^^^^^^^^^ help: replace it with: `problem` [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/algorithm.rs:85:19 [INFO] [stderr] | [INFO] [stderr] 85 | Results { problem: problem, parameters: params, [INFO] [stderr] | ^^^^^^^^^^^^^^^^ help: replace it with: `problem` [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/individual.rs:25:35 [INFO] [stderr] | [INFO] [stderr] 25 | Individual { solution: x, fitness: fitness, problem: problem } [INFO] [stderr] | ^^^^^^^^^^^^^^^^ help: replace it with: `fitness` [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/individual.rs:25:53 [INFO] [stderr] | [INFO] [stderr] 25 | Individual { solution: x, fitness: fitness, problem: problem } [INFO] [stderr] | ^^^^^^^^^^^^^^^^ help: replace it with: `problem` [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/algorithm.rs:64:21 [INFO] [stderr] | [INFO] [stderr] 64 | problem: problem, parameters: params, [INFO] [stderr] | ^^^^^^^^^^^^^^^^ help: replace it with: `problem` [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/algorithm.rs:85:19 [INFO] [stderr] | [INFO] [stderr] 85 | Results { problem: problem, parameters: params, [INFO] [stderr] | ^^^^^^^^^^^^^^^^ help: replace it with: `problem` [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/individual.rs:25:35 [INFO] [stderr] | [INFO] [stderr] 25 | Individual { solution: x, fitness: fitness, problem: problem } [INFO] [stderr] | ^^^^^^^^^^^^^^^^ help: replace it with: `fitness` [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/individual.rs:25:53 [INFO] [stderr] | [INFO] [stderr] 25 | Individual { solution: x, fitness: fitness, problem: problem } [INFO] [stderr] | ^^^^^^^^^^^^^^^^ help: replace it with: `problem` [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: use of deprecated item 'std::ascii::AsciiExt': use inherent methods instead [INFO] [stderr] --> src/main.rs:16:1 [INFO] [stderr] | [INFO] [stderr] 16 | / arg_enum!{ [INFO] [stderr] 17 | | #[derive(Debug, PartialEq, Eq, Copy, Clone)] [INFO] [stderr] 18 | | pub enum Problem { [INFO] [stderr] 19 | | Ackley, [INFO] [stderr] ... | [INFO] [stderr] 25 | | } [INFO] [stderr] 26 | | } [INFO] [stderr] | |_^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(deprecated)] on by default [INFO] [stderr] = note: this error originates in a macro outside of the current crate (in Nightly builds, run with -Z external-macro-backtrace for more info) [INFO] [stderr] [INFO] [stderr] warning: use of deprecated item 'std::ascii::AsciiExt': use inherent methods instead [INFO] [stderr] --> src/main.rs:16:1 [INFO] [stderr] | [INFO] [stderr] 16 | / arg_enum!{ [INFO] [stderr] 17 | | #[derive(Debug, PartialEq, Eq, Copy, Clone)] [INFO] [stderr] 18 | | pub enum Problem { [INFO] [stderr] 19 | | Ackley, [INFO] [stderr] ... | [INFO] [stderr] 25 | | } [INFO] [stderr] 26 | | } [INFO] [stderr] | |_^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(deprecated)] on by default [INFO] [stderr] = note: this error originates in a macro outside of the current crate (in Nightly builds, run with -Z external-macro-backtrace for more info) [INFO] [stderr] [INFO] [stderr] warning: this argument is passed by reference, but would be more efficient if passed by value [INFO] [stderr] --> src/problem.rs:21:20 [INFO] [stderr] | [INFO] [stderr] 21 | pub fn fitness(&self, x: &[f64]) -> f64 { [INFO] [stderr] | ^^^^^ help: consider passing by value instead: `self` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::trivially_copy_pass_by_ref)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#trivially_copy_pass_by_ref [INFO] [stderr] [INFO] [stderr] warning: this argument is passed by reference, but would be more efficient if passed by value [INFO] [stderr] --> src/problem.rs:57:19 [INFO] [stderr] | [INFO] [stderr] 57 | pub fn domain(&self) -> (f64, f64) { [INFO] [stderr] | ^^^^^ help: consider passing by value instead: `self` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#trivially_copy_pass_by_ref [INFO] [stderr] [INFO] [stderr] warning: this argument is passed by reference, but would be more efficient if passed by value [INFO] [stderr] --> src/problem.rs:69:24 [INFO] [stderr] | [INFO] [stderr] 69 | pub fn domain_dist(&self) -> Range { [INFO] [stderr] | ^^^^^ help: consider passing by value instead: `self` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#trivially_copy_pass_by_ref [INFO] [stderr] [INFO] [stderr] warning: use of `unwrap_or` followed by a function call [INFO] [stderr] --> src/main.rs:76:10 [INFO] [stderr] | [INFO] [stderr] 76 | .unwrap_or(vec![Problem::Ackley, Problem::Griewangk, Problem::Rastrigin, [INFO] [stderr] | __________^ [INFO] [stderr] 77 | | Problem::Rosenbrock, Problem::Schwefel, Problem::Sphere]); [INFO] [stderr] | |_________________________________________________________________________________^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::or_fun_call)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#or_fun_call [INFO] [stderr] help: try this [INFO] [stderr] | [INFO] [stderr] 76 | .unwrap_or_else(|_| vec![Problem::Ackley, Problem::Griewangk, Problem::Rastrigin, [INFO] [stderr] 77 | Problem::Rosenbrock, Problem::Schwefel, Problem::Sphere]); [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: this argument is passed by reference, but would be more efficient if passed by value [INFO] [stderr] --> src/problem.rs:21:20 [INFO] [stderr] | [INFO] [stderr] 21 | pub fn fitness(&self, x: &[f64]) -> f64 { [INFO] [stderr] | ^^^^^ help: consider passing by value instead: `self` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::trivially_copy_pass_by_ref)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#trivially_copy_pass_by_ref [INFO] [stderr] [INFO] [stderr] warning: this argument is passed by reference, but would be more efficient if passed by value [INFO] [stderr] --> src/problem.rs:57:19 [INFO] [stderr] | [INFO] [stderr] 57 | pub fn domain(&self) -> (f64, f64) { [INFO] [stderr] | ^^^^^ help: consider passing by value instead: `self` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#trivially_copy_pass_by_ref [INFO] [stderr] [INFO] [stderr] warning: this argument is passed by reference, but would be more efficient if passed by value [INFO] [stderr] --> src/problem.rs:69:24 [INFO] [stderr] | [INFO] [stderr] 69 | pub fn domain_dist(&self) -> Range { [INFO] [stderr] | ^^^^^ help: consider passing by value instead: `self` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#trivially_copy_pass_by_ref [INFO] [stderr] [INFO] [stderr] warning: use of `unwrap_or` followed by a function call [INFO] [stderr] --> src/main.rs:76:10 [INFO] [stderr] | [INFO] [stderr] 76 | .unwrap_or(vec![Problem::Ackley, Problem::Griewangk, Problem::Rastrigin, [INFO] [stderr] | __________^ [INFO] [stderr] 77 | | Problem::Rosenbrock, Problem::Schwefel, Problem::Sphere]); [INFO] [stderr] | |_________________________________________________________________________________^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::or_fun_call)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#or_fun_call [INFO] [stderr] help: try this [INFO] [stderr] | [INFO] [stderr] 76 | .unwrap_or_else(|_| vec![Problem::Ackley, Problem::Griewangk, Problem::Rastrigin, [INFO] [stderr] 77 | Problem::Rosenbrock, Problem::Schwefel, Problem::Sphere]); [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] Finished dev [optimized + debuginfo] target(s) in 5.52s [INFO] running `"docker" "inspect" "9cd8f45ebc9aa2c68b354a5ed4d768700eaed161516aac1c78de3f83e04825b6"` [INFO] running `"docker" "rm" "-f" "9cd8f45ebc9aa2c68b354a5ed4d768700eaed161516aac1c78de3f83e04825b6"` [INFO] [stdout] 9cd8f45ebc9aa2c68b354a5ed4d768700eaed161516aac1c78de3f83e04825b6