[INFO] updating cached repository xdavidel/rust-employee-salary-calc [INFO] running `"git" "fetch" "--all"` [INFO] [stdout] Fetching origin [INFO] [stderr] From git://github.com/xdavidel/rust-employee-salary-calc [INFO] [stderr] * branch HEAD -> FETCH_HEAD [INFO] running `"git" "clone" "work/cache/sources/gh/xdavidel/rust-employee-salary-calc" "work/ex/clippy-test-run/sources/stable/gh/xdavidel/rust-employee-salary-calc"` [INFO] [stderr] Cloning into 'work/ex/clippy-test-run/sources/stable/gh/xdavidel/rust-employee-salary-calc'... [INFO] [stderr] done. [INFO] running `"git" "clone" "work/cache/sources/gh/xdavidel/rust-employee-salary-calc" "work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/gh/xdavidel/rust-employee-salary-calc"` [INFO] [stderr] Cloning into 'work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/gh/xdavidel/rust-employee-salary-calc'... [INFO] [stderr] done. [INFO] running `"git" "rev-parse" "HEAD"` [INFO] [stdout] 88982ac911550773ef948de1ef305fc689c0a9a7 [INFO] sha for GitHub repo xdavidel/rust-employee-salary-calc: 88982ac911550773ef948de1ef305fc689c0a9a7 [INFO] validating manifest of xdavidel/rust-employee-salary-calc 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 xdavidel/rust-employee-salary-calc 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 xdavidel/rust-employee-salary-calc [INFO] finished frobbing xdavidel/rust-employee-salary-calc [INFO] frobbed toml for xdavidel/rust-employee-salary-calc written to work/ex/clippy-test-run/sources/stable/gh/xdavidel/rust-employee-salary-calc/Cargo.toml [INFO] started frobbing xdavidel/rust-employee-salary-calc [INFO] finished frobbing xdavidel/rust-employee-salary-calc [INFO] frobbed toml for xdavidel/rust-employee-salary-calc written to work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/gh/xdavidel/rust-employee-salary-calc/Cargo.toml [INFO] crate xdavidel/rust-employee-salary-calc 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 xdavidel/rust-employee-salary-calc 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/xdavidel/rust-employee-salary-calc:/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] 1486bb7d240f9eed80fb9600cb4b0bad0a6fd0b9d2aad259c92ba18e67680e5a [INFO] running `"docker" "start" "-a" "1486bb7d240f9eed80fb9600cb4b0bad0a6fd0b9d2aad259c92ba18e67680e5a"` [INFO] [stderr] Checking employee v0.1.0 (/opt/crater/workdir) [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/employee.rs:30:13 [INFO] [stderr] | [INFO] [stderr] 30 | name: name, [INFO] [stderr] | ^^^^^^^^^^ help: replace it with: `name` [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/employee.rs:31:13 [INFO] [stderr] | [INFO] [stderr] 31 | age: age, [INFO] [stderr] | ^^^^^^^^ help: replace it with: `age` [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/employee.rs:32:13 [INFO] [stderr] | [INFO] [stderr] 32 | salary: salary, [INFO] [stderr] | ^^^^^^^^^^^^^^ help: replace it with: `salary` [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/employee.rs:33:13 [INFO] [stderr] | [INFO] [stderr] 33 | raise_factor: raise_factor, [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `raise_factor` [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/employee.rs:30:13 [INFO] [stderr] | [INFO] [stderr] 30 | name: name, [INFO] [stderr] | ^^^^^^^^^^ help: replace it with: `name` [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/employee.rs:31:13 [INFO] [stderr] | [INFO] [stderr] 31 | age: age, [INFO] [stderr] | ^^^^^^^^ help: replace it with: `age` [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/employee.rs:32:13 [INFO] [stderr] | [INFO] [stderr] 32 | salary: salary, [INFO] [stderr] | ^^^^^^^^^^^^^^ help: replace it with: `salary` [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/employee.rs:33:13 [INFO] [stderr] | [INFO] [stderr] 33 | raise_factor: raise_factor, [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `raise_factor` [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: unneeded return statement [INFO] [stderr] --> src/employee.rs:25:9 [INFO] [stderr] | [INFO] [stderr] 25 | return salary; [INFO] [stderr] | ^^^^^^^^^^^^^^ help: remove `return` as shown: `salary` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::needless_return)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stderr] [INFO] [stderr] warning: unneeded return statement [INFO] [stderr] --> src/employee.rs:25:9 [INFO] [stderr] | [INFO] [stderr] 25 | return salary; [INFO] [stderr] | ^^^^^^^^^^^^^^ help: remove `return` as shown: `salary` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::needless_return)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stderr] [INFO] [stderr] warning: `if _ { .. } else { .. }` is an expression [INFO] [stderr] --> src/main.rs:14:5 [INFO] [stderr] | [INFO] [stderr] 14 | / let mut years = 3; [INFO] [stderr] 15 | | [INFO] [stderr] 16 | | if args.len() > 1 { [INFO] [stderr] 17 | | println!("Enter employee name:"); [INFO] [stderr] ... | [INFO] [stderr] 53 | | years = input.trim().parse().expect("Not a valid year"); [INFO] [stderr] 54 | | } [INFO] [stderr] | |_____^ help: it is more idiomatic to write: `let years = if args.len() > 1 { ..; input.trim().parse().expect("Not a valid year") } else { 3 };` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::useless_let_if_seq)] on by default [INFO] [stderr] = note: you might not need `mut` at all [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_let_if_seq [INFO] [stderr] [INFO] [stderr] warning: `if _ { .. } else { .. }` is an expression [INFO] [stderr] --> src/main.rs:14:5 [INFO] [stderr] | [INFO] [stderr] 14 | / let mut years = 3; [INFO] [stderr] 15 | | [INFO] [stderr] 16 | | if args.len() > 1 { [INFO] [stderr] 17 | | println!("Enter employee name:"); [INFO] [stderr] ... | [INFO] [stderr] 53 | | years = input.trim().parse().expect("Not a valid year"); [INFO] [stderr] 54 | | } [INFO] [stderr] | |_____^ help: it is more idiomatic to write: `let years = if args.len() > 1 { ..; input.trim().parse().expect("Not a valid year") } else { 3 };` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::useless_let_if_seq)] on by default [INFO] [stderr] = note: you might not need `mut` at all [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_let_if_seq [INFO] [stderr] [INFO] [stderr] Finished dev [unoptimized + debuginfo] target(s) in 0.45s [INFO] running `"docker" "inspect" "1486bb7d240f9eed80fb9600cb4b0bad0a6fd0b9d2aad259c92ba18e67680e5a"` [INFO] running `"docker" "rm" "-f" "1486bb7d240f9eed80fb9600cb4b0bad0a6fd0b9d2aad259c92ba18e67680e5a"` [INFO] [stdout] 1486bb7d240f9eed80fb9600cb4b0bad0a6fd0b9d2aad259c92ba18e67680e5a