[INFO] crate g-k-crates-io-client 0.16.0 is already in cache [INFO] extracting crate g-k-crates-io-client 0.16.0 into work/ex/clippy-test-run/sources/stable/reg/g-k-crates-io-client/0.16.0 [INFO] extracting crate g-k-crates-io-client 0.16.0 into work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/reg/g-k-crates-io-client/0.16.0 [INFO] validating manifest of g-k-crates-io-client-0.16.0 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 g-k-crates-io-client-0.16.0 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 g-k-crates-io-client-0.16.0 [INFO] finished frobbing g-k-crates-io-client-0.16.0 [INFO] frobbed toml for g-k-crates-io-client-0.16.0 written to work/ex/clippy-test-run/sources/stable/reg/g-k-crates-io-client/0.16.0/Cargo.toml [INFO] started frobbing g-k-crates-io-client-0.16.0 [INFO] finished frobbing g-k-crates-io-client-0.16.0 [INFO] frobbed toml for g-k-crates-io-client-0.16.0 written to work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/reg/g-k-crates-io-client/0.16.0/Cargo.toml [INFO] running `"/mnt/big/crater/work/local/cargo-home/bin/cargo" "+stable" "generate-lockfile" "--manifest-path" "Cargo.toml" "-Zno-index-update"` [INFO] running `"/mnt/big/crater/work/local/cargo-home/bin/cargo" "+stable" "generate-lockfile" "--manifest-path" "Cargo.toml" "-Zno-index-update"` [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 g-k-crates-io-client-0.16.0 against stable for clippy-test-run [INFO] running `"docker" "create" "-v" "/mnt/big/crater/work/local/target-dirs/clippy-test-run/worker-5/stable:/opt/crater/target:rw,Z" "-v" "/mnt/big/crater/work/ex/clippy-test-run/sources/stable/reg/g-k-crates-io-client/0.16.0:/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] fcc640e3004b1a58dbbc8221d6d1414a47a994024c69c7b4a22c99786f1b4a8c [INFO] running `"docker" "start" "-a" "fcc640e3004b1a58dbbc8221d6d1414a47a994024c69c7b4a22c99786f1b4a8c"` [INFO] [stderr] Compiling curl-sys v0.4.16 [INFO] [stderr] Checking curl v0.4.19 [INFO] [stderr] Checking g-k-crates-io-client v0.16.0 (/opt/crater/workdir) [INFO] [stderr] warning: You are using an explicit closure for cloning elements [INFO] [stderr] --> lib.rs:179:17 [INFO] [stderr] | [INFO] [stderr] 179 | / [ [INFO] [stderr] 180 | | (json.len() >> 0) as u8, [INFO] [stderr] 181 | | (json.len() >> 8) as u8, [INFO] [stderr] 182 | | (json.len() >> 16) as u8, [INFO] [stderr] 183 | | (json.len() >> 24) as u8, [INFO] [stderr] 184 | | ].iter() [INFO] [stderr] 185 | | .map(|x| *x), [INFO] [stderr] | |________________________________^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::map_clone)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stderr] help: Consider calling the dedicated `cloned` method [INFO] [stderr] | [INFO] [stderr] 179 | [ [INFO] [stderr] 180 | (json.len() >> 0) as u8, [INFO] [stderr] 181 | (json.len() >> 8) as u8, [INFO] [stderr] 182 | (json.len() >> 16) as u8, [INFO] [stderr] 183 | (json.len() >> 24) as u8, [INFO] [stderr] 184 | ].iter().cloned(), [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: the operation is ineffective. Consider reducing it to `json.len()` [INFO] [stderr] --> lib.rs:180:21 [INFO] [stderr] | [INFO] [stderr] 180 | (json.len() >> 0) as u8, [INFO] [stderr] | ^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::identity_op)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stderr] [INFO] [stderr] warning: You are using an explicit closure for cloning elements [INFO] [stderr] --> lib.rs:187:22 [INFO] [stderr] | [INFO] [stderr] 187 | w.extend(json.as_bytes().iter().map(|x| *x)); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: Consider calling the dedicated `cloned` method: `json.as_bytes().iter().cloned()` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stderr] [INFO] [stderr] warning: You are using an explicit closure for cloning elements [INFO] [stderr] --> lib.rs:189:17 [INFO] [stderr] | [INFO] [stderr] 189 | / [ [INFO] [stderr] 190 | | (stat.len() >> 0) as u8, [INFO] [stderr] 191 | | (stat.len() >> 8) as u8, [INFO] [stderr] 192 | | (stat.len() >> 16) as u8, [INFO] [stderr] 193 | | (stat.len() >> 24) as u8, [INFO] [stderr] 194 | | ].iter() [INFO] [stderr] 195 | | .map(|x| *x), [INFO] [stderr] | |________________________________^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stderr] help: Consider calling the dedicated `cloned` method [INFO] [stderr] | [INFO] [stderr] 189 | [ [INFO] [stderr] 190 | (stat.len() >> 0) as u8, [INFO] [stderr] 191 | (stat.len() >> 8) as u8, [INFO] [stderr] 192 | (stat.len() >> 16) as u8, [INFO] [stderr] 193 | (stat.len() >> 24) as u8, [INFO] [stderr] 194 | ].iter().cloned(), [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: the operation is ineffective. Consider reducing it to `stat.len()` [INFO] [stderr] --> lib.rs:190:21 [INFO] [stderr] | [INFO] [stderr] 190 | (stat.len() >> 0) as u8, [INFO] [stderr] | ^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stderr] [INFO] [stderr] warning: length comparison to zero [INFO] [stderr] --> lib.rs:218:27 [INFO] [stderr] | [INFO] [stderr] 218 | let response = if body.len() > 0 { [INFO] [stderr] | ^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `!body.is_empty()` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::len_zero)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stderr] [INFO] [stderr] warning: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` [INFO] [stderr] --> lib.rs:346:5 [INFO] [stderr] | [INFO] [stderr] 346 | / match serde_json::from_str::(&body) { [INFO] [stderr] 347 | | Ok(errors) => { [INFO] [stderr] 348 | | let errors = errors.errors.into_iter().map(|s| s.detail); [INFO] [stderr] 349 | | bail!("api errors: {}", errors.collect::>().join(", ")) [INFO] [stderr] 350 | | } [INFO] [stderr] 351 | | Err(..) => {} [INFO] [stderr] 352 | | } [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] 346 | if let Ok(errors) = serde_json::from_str::(&body) { [INFO] [stderr] 347 | let errors = errors.errors.into_iter().map(|s| s.detail); [INFO] [stderr] 348 | bail!("api errors: {}", errors.collect::>().join(", ")) [INFO] [stderr] 349 | } [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: You are using an explicit closure for cloning elements [INFO] [stderr] --> lib.rs:179:17 [INFO] [stderr] | [INFO] [stderr] 179 | / [ [INFO] [stderr] 180 | | (json.len() >> 0) as u8, [INFO] [stderr] 181 | | (json.len() >> 8) as u8, [INFO] [stderr] 182 | | (json.len() >> 16) as u8, [INFO] [stderr] 183 | | (json.len() >> 24) as u8, [INFO] [stderr] 184 | | ].iter() [INFO] [stderr] 185 | | .map(|x| *x), [INFO] [stderr] | |________________________________^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::map_clone)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stderr] help: Consider calling the dedicated `cloned` method [INFO] [stderr] | [INFO] [stderr] 179 | [ [INFO] [stderr] 180 | (json.len() >> 0) as u8, [INFO] [stderr] 181 | (json.len() >> 8) as u8, [INFO] [stderr] 182 | (json.len() >> 16) as u8, [INFO] [stderr] 183 | (json.len() >> 24) as u8, [INFO] [stderr] 184 | ].iter().cloned(), [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: the operation is ineffective. Consider reducing it to `json.len()` [INFO] [stderr] --> lib.rs:180:21 [INFO] [stderr] | [INFO] [stderr] 180 | (json.len() >> 0) as u8, [INFO] [stderr] | ^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::identity_op)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stderr] [INFO] [stderr] warning: You are using an explicit closure for cloning elements [INFO] [stderr] --> lib.rs:187:22 [INFO] [stderr] | [INFO] [stderr] 187 | w.extend(json.as_bytes().iter().map(|x| *x)); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: Consider calling the dedicated `cloned` method: `json.as_bytes().iter().cloned()` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stderr] [INFO] [stderr] warning: You are using an explicit closure for cloning elements [INFO] [stderr] --> lib.rs:189:17 [INFO] [stderr] | [INFO] [stderr] 189 | / [ [INFO] [stderr] 190 | | (stat.len() >> 0) as u8, [INFO] [stderr] 191 | | (stat.len() >> 8) as u8, [INFO] [stderr] 192 | | (stat.len() >> 16) as u8, [INFO] [stderr] 193 | | (stat.len() >> 24) as u8, [INFO] [stderr] 194 | | ].iter() [INFO] [stderr] 195 | | .map(|x| *x), [INFO] [stderr] | |________________________________^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stderr] help: Consider calling the dedicated `cloned` method [INFO] [stderr] | [INFO] [stderr] 189 | [ [INFO] [stderr] 190 | (stat.len() >> 0) as u8, [INFO] [stderr] 191 | (stat.len() >> 8) as u8, [INFO] [stderr] 192 | (stat.len() >> 16) as u8, [INFO] [stderr] 193 | (stat.len() >> 24) as u8, [INFO] [stderr] 194 | ].iter().cloned(), [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] warning: the operation is ineffective. Consider reducing it to `stat.len()` [INFO] [stderr] --> lib.rs:190:21 [INFO] [stderr] | [INFO] [stderr] 190 | (stat.len() >> 0) as u8, [INFO] [stderr] | ^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stderr] [INFO] [stderr] warning: length comparison to zero [INFO] [stderr] --> lib.rs:218:27 [INFO] [stderr] | [INFO] [stderr] 218 | let response = if body.len() > 0 { [INFO] [stderr] | ^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `!body.is_empty()` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::len_zero)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stderr] [INFO] [stderr] warning: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` [INFO] [stderr] --> lib.rs:346:5 [INFO] [stderr] | [INFO] [stderr] 346 | / match serde_json::from_str::(&body) { [INFO] [stderr] 347 | | Ok(errors) => { [INFO] [stderr] 348 | | let errors = errors.errors.into_iter().map(|s| s.detail); [INFO] [stderr] 349 | | bail!("api errors: {}", errors.collect::>().join(", ")) [INFO] [stderr] 350 | | } [INFO] [stderr] 351 | | Err(..) => {} [INFO] [stderr] 352 | | } [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] 346 | if let Ok(errors) = serde_json::from_str::(&body) { [INFO] [stderr] 347 | let errors = errors.errors.into_iter().map(|s| s.detail); [INFO] [stderr] 348 | bail!("api errors: {}", errors.collect::>().join(", ")) [INFO] [stderr] 349 | } [INFO] [stderr] | [INFO] [stderr] [INFO] [stderr] Finished dev [unoptimized + debuginfo] target(s) in 23.21s [INFO] running `"docker" "inspect" "fcc640e3004b1a58dbbc8221d6d1414a47a994024c69c7b4a22c99786f1b4a8c"` [INFO] running `"docker" "rm" "-f" "fcc640e3004b1a58dbbc8221d6d1414a47a994024c69c7b4a22c99786f1b4a8c"` [INFO] [stdout] fcc640e3004b1a58dbbc8221d6d1414a47a994024c69c7b4a22c99786f1b4a8c