[INFO] crate ssh_bookmarker 1.0.0 is already in cache [INFO] extracting crate ssh_bookmarker 1.0.0 into work/ex/clippy-test-run/sources/stable/reg/ssh_bookmarker/1.0.0 [INFO] extracting crate ssh_bookmarker 1.0.0 into work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/reg/ssh_bookmarker/1.0.0 [INFO] validating manifest of ssh_bookmarker-1.0.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 ssh_bookmarker-1.0.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 ssh_bookmarker-1.0.0 [INFO] finished frobbing ssh_bookmarker-1.0.0 [INFO] frobbed toml for ssh_bookmarker-1.0.0 written to work/ex/clippy-test-run/sources/stable/reg/ssh_bookmarker/1.0.0/Cargo.toml [INFO] started frobbing ssh_bookmarker-1.0.0 [INFO] finished frobbing ssh_bookmarker-1.0.0 [INFO] frobbed toml for ssh_bookmarker-1.0.0 written to work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/reg/ssh_bookmarker/1.0.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 ssh_bookmarker-1.0.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/ssh_bookmarker/1.0.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] fb00d120915fb44957fcec9606a44197b68524fa6aa5712cfdfbd8645f4a3984 [INFO] running `"docker" "start" "-a" "fb00d120915fb44957fcec9606a44197b68524fa6aa5712cfdfbd8645f4a3984"` [INFO] [stderr] Checking ssh_bookmarker v1.0.0 (/opt/crater/workdir) [INFO] [stderr] warning: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) [INFO] [stderr] --> src/ssh_config/mod.rs:19:5 [INFO] [stderr] | [INFO] [stderr] 19 | / fn pathname<'a>(&'a self) -> &'a Path { [INFO] [stderr] 20 | | self.pathname.as_path() [INFO] [stderr] 21 | | } [INFO] [stderr] | |_____^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::needless_lifetimes)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stderr] [INFO] [stderr] warning: length comparison to zero [INFO] [stderr] --> src/ssh_config/mod.rs:30:16 [INFO] [stderr] | [INFO] [stderr] 30 | if line.len() == 0 || line.starts_with('#') { [INFO] [stderr] | ^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `line.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: single-character string constant used as pattern [INFO] [stderr] --> src/ssh_config/mod.rs:37:48 [INFO] [stderr] | [INFO] [stderr] 37 | protocols = annotated[1].split(",").collect(); [INFO] [stderr] | ^^^ help: try using a char instead: `','` [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: this .into_iter() call is equivalent to .iter() and will not move the slice [INFO] [stderr] --> src/ssh_config/mod.rs:43:58 [INFO] [stderr] | [INFO] [stderr] 43 | hosts.extend(host_entries.as_slice().into_iter().map(|name| Host::new(name, proto))) [INFO] [stderr] | ^^^^^^^^^ help: call directly: `iter` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::into_iter_on_ref)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#into_iter_on_ref [INFO] [stderr] [INFO] [stderr] warning: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) [INFO] [stderr] --> src/known_hosts/mod.rs:19:5 [INFO] [stderr] | [INFO] [stderr] 19 | / fn pathname<'a>(&'a self) -> &'a Path { [INFO] [stderr] 20 | | self.pathname.as_path() [INFO] [stderr] 21 | | } [INFO] [stderr] | |_____^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stderr] [INFO] [stderr] warning: length comparison to zero [INFO] [stderr] --> src/known_hosts/mod.rs:38:8 [INFO] [stderr] | [INFO] [stderr] 38 | if line.len() == 0 || line.starts_with('#') { [INFO] [stderr] | ^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `line.is_empty()` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stderr] [INFO] [stderr] warning: use of `ok_or` followed by a function call [INFO] [stderr] --> src/known_hosts/mod.rs:43:43 [INFO] [stderr] | [INFO] [stderr] 43 | let mut host_item = try!(items.next().ok_or(ErrorKind::KnownHostFormat(pathname.to_path_buf(), lineno, line.to_string()))); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `ok_or_else(|| ErrorKind::KnownHostFormat(pathname.to_path_buf(), lineno, line.to_string()))` [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 `ok_or` followed by a function call [INFO] [stderr] --> src/known_hosts/mod.rs:46:39 [INFO] [stderr] | [INFO] [stderr] 46 | host_item = try!(items.next().ok_or(ErrorKind::KnownHostFormat(pathname.to_path_buf(), lineno, line.to_string()))); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `ok_or_else(|| ErrorKind::KnownHostFormat(pathname.to_path_buf(), lineno, line.to_string()))` [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: this .into_iter() call is equivalent to .iter() and will not move the slice [INFO] [stderr] --> src/launchagent/mod.rs:14:26 [INFO] [stderr] | [INFO] [stderr] 14 | prefix_iter.zip(args.into_iter()).flat_map(|(p, arg)| vec![p, arg]).collect() [INFO] [stderr] | ^^^^^^^^^ help: call directly: `iter` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#into_iter_on_ref [INFO] [stderr] [INFO] [stderr] warning: length comparison to zero [INFO] [stderr] --> src/launchagent/mod.rs:18:8 [INFO] [stderr] | [INFO] [stderr] 18 | if args.len() > 0 { [INFO] [stderr] | ^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `!args.is_empty()` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stderr] [INFO] [stderr] warning: this pattern takes a reference on something that is being de-referenced [INFO] [stderr] --> src/launchagent/mod.rs:29:50 [INFO] [stderr] | [INFO] [stderr] 29 | let configs: Vec<&str> = configs.iter().map(|&ref s| s.as_str()).collect(); [INFO] [stderr] | ^^^^^^ help: try removing the `&ref` part and just keep: `s` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::needless_borrowed_reference)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrowed_reference [INFO] [stderr] [INFO] [stderr] warning: this pattern takes a reference on something that is being de-referenced [INFO] [stderr] --> src/launchagent/mod.rs:31:58 [INFO] [stderr] | [INFO] [stderr] 31 | let known_hosts: Vec<&str> = known_hosts.iter().map(|&ref s| s.as_str()).collect(); [INFO] [stderr] | ^^^^^^ help: try removing the `&ref` part and just keep: `s` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrowed_reference [INFO] [stderr] [INFO] [stderr] warning: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) [INFO] [stderr] --> src/lib.rs:67:5 [INFO] [stderr] | [INFO] [stderr] 67 | fn pathname<'a>(&'a self) -> &'a Path; [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stderr] [INFO] [stderr] warning: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) [INFO] [stderr] --> src/ssh_config/mod.rs:19:5 [INFO] [stderr] | [INFO] [stderr] 19 | / fn pathname<'a>(&'a self) -> &'a Path { [INFO] [stderr] 20 | | self.pathname.as_path() [INFO] [stderr] 21 | | } [INFO] [stderr] | |_____^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::needless_lifetimes)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stderr] [INFO] [stderr] warning: length comparison to zero [INFO] [stderr] --> src/ssh_config/mod.rs:30:16 [INFO] [stderr] | [INFO] [stderr] 30 | if line.len() == 0 || line.starts_with('#') { [INFO] [stderr] | ^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `line.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: single-character string constant used as pattern [INFO] [stderr] --> src/ssh_config/mod.rs:37:48 [INFO] [stderr] | [INFO] [stderr] 37 | protocols = annotated[1].split(",").collect(); [INFO] [stderr] | ^^^ help: try using a char instead: `','` [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: this .into_iter() call is equivalent to .iter() and will not move the slice [INFO] [stderr] --> src/ssh_config/mod.rs:43:58 [INFO] [stderr] | [INFO] [stderr] 43 | hosts.extend(host_entries.as_slice().into_iter().map(|name| Host::new(name, proto))) [INFO] [stderr] | ^^^^^^^^^ help: call directly: `iter` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::into_iter_on_ref)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#into_iter_on_ref [INFO] [stderr] [INFO] [stderr] warning: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) [INFO] [stderr] --> src/known_hosts/mod.rs:19:5 [INFO] [stderr] | [INFO] [stderr] 19 | / fn pathname<'a>(&'a self) -> &'a Path { [INFO] [stderr] 20 | | self.pathname.as_path() [INFO] [stderr] 21 | | } [INFO] [stderr] | |_____^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stderr] [INFO] [stderr] warning: length comparison to zero [INFO] [stderr] --> src/known_hosts/mod.rs:38:8 [INFO] [stderr] | [INFO] [stderr] 38 | if line.len() == 0 || line.starts_with('#') { [INFO] [stderr] | ^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `line.is_empty()` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stderr] [INFO] [stderr] warning: use of `ok_or` followed by a function call [INFO] [stderr] --> src/known_hosts/mod.rs:43:43 [INFO] [stderr] | [INFO] [stderr] 43 | let mut host_item = try!(items.next().ok_or(ErrorKind::KnownHostFormat(pathname.to_path_buf(), lineno, line.to_string()))); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `ok_or_else(|| ErrorKind::KnownHostFormat(pathname.to_path_buf(), lineno, line.to_string()))` [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 `ok_or` followed by a function call [INFO] [stderr] --> src/known_hosts/mod.rs:46:39 [INFO] [stderr] | [INFO] [stderr] 46 | host_item = try!(items.next().ok_or(ErrorKind::KnownHostFormat(pathname.to_path_buf(), lineno, line.to_string()))); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `ok_or_else(|| ErrorKind::KnownHostFormat(pathname.to_path_buf(), lineno, line.to_string()))` [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: this .into_iter() call is equivalent to .iter() and will not move the slice [INFO] [stderr] --> src/launchagent/mod.rs:14:26 [INFO] [stderr] | [INFO] [stderr] 14 | prefix_iter.zip(args.into_iter()).flat_map(|(p, arg)| vec![p, arg]).collect() [INFO] [stderr] | ^^^^^^^^^ help: call directly: `iter` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#into_iter_on_ref [INFO] [stderr] [INFO] [stderr] warning: length comparison to zero [INFO] [stderr] --> src/launchagent/mod.rs:18:8 [INFO] [stderr] | [INFO] [stderr] 18 | if args.len() > 0 { [INFO] [stderr] | ^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `!args.is_empty()` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stderr] [INFO] [stderr] warning: this pattern takes a reference on something that is being de-referenced [INFO] [stderr] --> src/launchagent/mod.rs:29:50 [INFO] [stderr] | [INFO] [stderr] 29 | let configs: Vec<&str> = configs.iter().map(|&ref s| s.as_str()).collect(); [INFO] [stderr] | ^^^^^^ help: try removing the `&ref` part and just keep: `s` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::needless_borrowed_reference)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrowed_reference [INFO] [stderr] [INFO] [stderr] warning: this pattern takes a reference on something that is being de-referenced [INFO] [stderr] --> src/launchagent/mod.rs:31:58 [INFO] [stderr] | [INFO] [stderr] 31 | let known_hosts: Vec<&str> = known_hosts.iter().map(|&ref s| s.as_str()).collect(); [INFO] [stderr] | ^^^^^^ help: try removing the `&ref` part and just keep: `s` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrowed_reference [INFO] [stderr] [INFO] [stderr] warning: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) [INFO] [stderr] --> src/lib.rs:67:5 [INFO] [stderr] | [INFO] [stderr] 67 | fn pathname<'a>(&'a self) -> &'a Path; [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes [INFO] [stderr] [INFO] [stderr] warning: Constants have by default a `'static` lifetime [INFO] [stderr] --> src/main.rs:18:15 [INFO] [stderr] | [INFO] [stderr] 18 | const USAGE: &'static str = " [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: Constants have by default a `'static` lifetime [INFO] [stderr] --> src/main.rs:18:15 [INFO] [stderr] | [INFO] [stderr] 18 | const USAGE: &'static str = " [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] Finished dev [unoptimized + debuginfo] target(s) in 2.51s [INFO] running `"docker" "inspect" "fb00d120915fb44957fcec9606a44197b68524fa6aa5712cfdfbd8645f4a3984"` [INFO] running `"docker" "rm" "-f" "fb00d120915fb44957fcec9606a44197b68524fa6aa5712cfdfbd8645f4a3984"` [INFO] [stdout] fb00d120915fb44957fcec9606a44197b68524fa6aa5712cfdfbd8645f4a3984