[INFO] crate robotparser 0.10.2 is already in cache [INFO] extracting crate robotparser 0.10.2 into work/ex/clippy-test-run/sources/stable/reg/robotparser/0.10.2 [INFO] extracting crate robotparser 0.10.2 into work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/reg/robotparser/0.10.2 [INFO] validating manifest of robotparser-0.10.2 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 robotparser-0.10.2 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 robotparser-0.10.2 [INFO] finished frobbing robotparser-0.10.2 [INFO] frobbed toml for robotparser-0.10.2 written to work/ex/clippy-test-run/sources/stable/reg/robotparser/0.10.2/Cargo.toml [INFO] started frobbing robotparser-0.10.2 [INFO] finished frobbing robotparser-0.10.2 [INFO] frobbed toml for robotparser-0.10.2 written to work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/reg/robotparser/0.10.2/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 robotparser-0.10.2 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/robotparser/0.10.2:/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] ec69908a333cb676ab0cba922296d9025f4352933b672192fc207a4980e27d18 [INFO] running `"docker" "start" "-a" "ec69908a333cb676ab0cba922296d9025f4352933b672192fc207a4980e27d18"` [INFO] [stderr] Checking robotparser v0.10.2 (/opt/crater/workdir) [INFO] [stderr] warning: redundant field names in struct initialization [INFO] [stderr] --> src/lib.rs:104:13 [INFO] [stderr] | [INFO] [stderr] 104 | path: path, [INFO] [stderr] | ^^^^^^^^^^ help: replace it with: `path` [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/lib.rs:104:13 [INFO] [stderr] | [INFO] [stderr] 104 | path: path, [INFO] [stderr] | ^^^^^^^^^^ help: replace it with: `path` [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: `if _ { .. } else { .. }` is an expression [INFO] [stderr] --> src/lib.rs:98:9 [INFO] [stderr] | [INFO] [stderr] 98 | / let mut allow = allowance; [INFO] [stderr] 99 | | if path == "" && !allowance { [INFO] [stderr] 100 | | // an empty value means allow all [INFO] [stderr] 101 | | allow = true; [INFO] [stderr] 102 | | } [INFO] [stderr] | |_________^ help: it is more idiomatic to write: `let allow = if path == "" && !allowance { true } else { allowance };` [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/lib.rs:98:9 [INFO] [stderr] | [INFO] [stderr] 98 | / let mut allow = allowance; [INFO] [stderr] 99 | | if path == "" && !allowance { [INFO] [stderr] 100 | | // an empty value means allow all [INFO] [stderr] 101 | | allow = true; [INFO] [stderr] 102 | | } [INFO] [stderr] | |_________^ help: it is more idiomatic to write: `let allow = if path == "" && !allowance { true } else { allowance };` [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: methods called `from_*` usually take no self; consider choosing a less ambiguous name [INFO] [stderr] --> src/lib.rs:277:26 [INFO] [stderr] | [INFO] [stderr] 277 | pub fn from_response(&self, response: &mut Response) { [INFO] [stderr] | ^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::wrong_self_convention)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wrong_self_convention [INFO] [stderr] [INFO] [stderr] warning: methods called `from_*` usually take no self; consider choosing a less ambiguous name [INFO] [stderr] --> src/lib.rs:277:26 [INFO] [stderr] | [INFO] [stderr] 277 | pub fn from_response(&self, response: &mut Response) { [INFO] [stderr] | ^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::wrong_self_convention)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wrong_self_convention [INFO] [stderr] [INFO] [stderr] warning: use of `unwrap_or` followed by a function call [INFO] [stderr] --> src/lib.rs:343:22 [INFO] [stderr] | [INFO] [stderr] 343 | .unwrap_or("".to_owned()); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `unwrap_or_else(|_| "".to_owned())` [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] [INFO] [stderr] warning: use of `unwrap_or` followed by a function call [INFO] [stderr] --> src/lib.rs:343:22 [INFO] [stderr] | [INFO] [stderr] 343 | .unwrap_or("".to_owned()); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `unwrap_or_else(|_| "".to_owned())` [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] [INFO] [stderr] warning: use of `unwrap_or` followed by a function call [INFO] [stderr] --> src/lib.rs:426:94 [INFO] [stderr] | [INFO] [stderr] 426 | let decoded_url = String::from_utf8(percent_decode(url.trim().as_bytes()).collect()).unwrap_or("".to_owned()); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `unwrap_or_else(|_| "".to_owned())` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#or_fun_call [INFO] [stderr] [INFO] [stderr] warning: use of `unwrap_or` followed by a function call [INFO] [stderr] --> src/lib.rs:426:94 [INFO] [stderr] | [INFO] [stderr] 426 | let decoded_url = String::from_utf8(percent_decode(url.trim().as_bytes()).collect()).unwrap_or("".to_owned()); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `unwrap_or_else(|_| "".to_owned())` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#or_fun_call [INFO] [stderr] [INFO] [stderr] warning: Constants have by default a `'static` lifetime [INFO] [stderr] --> tests/lib.rs:8:15 [INFO] [stderr] | [INFO] [stderr] 8 | const AGENT: &'static str = "test_robotparser"; [INFO] [stderr] | -^^^^^^^---- help: consider removing `'static`: `&str` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::const_static_lifetime)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#const_static_lifetime [INFO] [stderr] [INFO] [stderr] warning: single-character string constant used as pattern [INFO] [stderr] --> tests/lib.rs:12:38 [INFO] [stderr] | [INFO] [stderr] 12 | let lines: Vec<&str> = doc.split("\n").collect(); [INFO] [stderr] | ^^^^ help: try using a char instead: `'\n'` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::single_char_pattern)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_char_pattern [INFO] [stderr] [INFO] [stderr] warning: single-character string constant used as pattern [INFO] [stderr] --> tests/lib.rs:230:38 [INFO] [stderr] | [INFO] [stderr] 230 | let lines: Vec<&str> = doc.split("\n").collect(); [INFO] [stderr] | ^^^^ help: try using a char instead: `'\n'` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_char_pattern [INFO] [stderr] [INFO] [stderr] warning: single-character string constant used as pattern [INFO] [stderr] --> tests/lib.rs:243:38 [INFO] [stderr] | [INFO] [stderr] 243 | let lines: Vec<&str> = doc.split("\n").collect(); [INFO] [stderr] | ^^^^ help: try using a char instead: `'\n'` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_char_pattern [INFO] [stderr] [INFO] [stderr] warning: single-character string constant used as pattern [INFO] [stderr] --> tests/lib.rs:262:38 [INFO] [stderr] | [INFO] [stderr] 262 | let lines: Vec<&str> = doc.split("\n").collect(); [INFO] [stderr] | ^^^^ help: try using a char instead: `'\n'` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_char_pattern [INFO] [stderr] [INFO] [stderr] Finished dev [unoptimized + debuginfo] target(s) in 10.02s [INFO] running `"docker" "inspect" "ec69908a333cb676ab0cba922296d9025f4352933b672192fc207a4980e27d18"` [INFO] running `"docker" "rm" "-f" "ec69908a333cb676ab0cba922296d9025f4352933b672192fc207a4980e27d18"` [INFO] [stdout] ec69908a333cb676ab0cba922296d9025f4352933b672192fc207a4980e27d18