[INFO] crate truecase 0.2.0 is already in cache [INFO] extracting crate truecase 0.2.0 into work/ex/clippy-test-run/sources/stable/reg/truecase/0.2.0 [INFO] extracting crate truecase 0.2.0 into work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/reg/truecase/0.2.0 [INFO] validating manifest of truecase-0.2.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 truecase-0.2.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 truecase-0.2.0 [INFO] finished frobbing truecase-0.2.0 [INFO] frobbed toml for truecase-0.2.0 written to work/ex/clippy-test-run/sources/stable/reg/truecase/0.2.0/Cargo.toml [INFO] started frobbing truecase-0.2.0 [INFO] finished frobbing truecase-0.2.0 [INFO] frobbed toml for truecase-0.2.0 written to work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/reg/truecase/0.2.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 truecase-0.2.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/truecase/0.2.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] d00582ff5cf0131bc035bb9e31a0742b86796cdc2cb00ccc678d8cd2b002562a [INFO] running `"docker" "start" "-a" "d00582ff5cf0131bc035bb9e31a0742b86796cdc2cb00ccc678d8cd2b002562a"` [INFO] [stderr] Checking criterion v0.2.9 [INFO] [stderr] Checking truecase v0.2.0 (/opt/crater/workdir) [INFO] [stderr] warning: this .into_iter() call is equivalent to .iter() and will not move the slice [INFO] [stderr] --> src/trainer.rs:99:59 [INFO] [stderr] | [INFO] [stderr] 99 | .map(|whatever| join_with_spaces(whatever.into_iter())); [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: this .into_iter() call is equivalent to .iter() and will not move the slice [INFO] [stderr] --> src/trainer.rs:102:59 [INFO] [stderr] | [INFO] [stderr] 102 | .map(|whatever| join_with_spaces(whatever.into_iter())); [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: called `.get().unwrap()` on a HashMap. Using `[]` is more clear and more concise [INFO] [stderr] --> src/trainer.rs:106:32 [INFO] [stderr] | [INFO] [stderr] 106 | .any(|(k, v)| *bigrams.get(&k).unwrap() != v) [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `&bigrams[&k]` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::get_unwrap)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_unwrap [INFO] [stderr] [INFO] [stderr] warning: called `.get().unwrap()` on a HashMap. Using `[]` is more clear and more concise [INFO] [stderr] --> src/trainer.rs:114:31 [INFO] [stderr] | [INFO] [stderr] 114 | .any(|(k, v)| unigrams.get(k).unwrap() != v) [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `&unigrams[k]` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_unwrap [INFO] [stderr] [INFO] [stderr] warning: methods called `to_*` usually take self by reference; consider choosing a less ambiguous name [INFO] [stderr] --> src/trainer.rs:210:23 [INFO] [stderr] | [INFO] [stderr] 210 | fn to_string_from(self, normalized: &str) -> String { [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: length comparison to zero [INFO] [stderr] --> src/trainer.rs:220:12 [INFO] [stderr] | [INFO] [stderr] 220 | && sentence.trim().len() > 0 [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `!sentence.trim().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: use of deprecated item 'failure::Error::causes': please use the 'iter_chain()' method instead [INFO] [stderr] --> src/main.rs:149:26 [INFO] [stderr] | [INFO] [stderr] 149 | for failure in error.causes() { [INFO] [stderr] | ^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(deprecated)] on by default [INFO] [stderr] [INFO] [stderr] warning: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` [INFO] [stderr] --> src/main.rs:75:9 [INFO] [stderr] | [INFO] [stderr] 75 | / match do_train(input_filenames, output_filename) { [INFO] [stderr] 76 | | Err(error) => print_error(error), [INFO] [stderr] 77 | | Ok(_) => {} [INFO] [stderr] 78 | | } [INFO] [stderr] | |_________^ help: try this: `if let Err(error) = do_train(input_filenames, output_filename) { print_error(error) }` [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] [INFO] [stderr] warning: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` [INFO] [stderr] --> src/main.rs:87:9 [INFO] [stderr] | [INFO] [stderr] 87 | / match do_truecase(model_filename, input_filename, output_filename) { [INFO] [stderr] 88 | | Err(error) => print_error(error), [INFO] [stderr] 89 | | Ok(_) => {} [INFO] [stderr] 90 | | }; [INFO] [stderr] | |_________^ help: try this: `if let Err(error) = do_truecase(model_filename, input_filename, output_filename) { print_error(error) }` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match [INFO] [stderr] [INFO] [stderr] warning: this .into_iter() call is equivalent to .iter() and will not move the slice [INFO] [stderr] --> src/trainer.rs:99:59 [INFO] [stderr] | [INFO] [stderr] 99 | .map(|whatever| join_with_spaces(whatever.into_iter())); [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: this .into_iter() call is equivalent to .iter() and will not move the slice [INFO] [stderr] --> src/trainer.rs:102:59 [INFO] [stderr] | [INFO] [stderr] 102 | .map(|whatever| join_with_spaces(whatever.into_iter())); [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: called `.get().unwrap()` on a HashMap. Using `[]` is more clear and more concise [INFO] [stderr] --> src/trainer.rs:106:32 [INFO] [stderr] | [INFO] [stderr] 106 | .any(|(k, v)| *bigrams.get(&k).unwrap() != v) [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `&bigrams[&k]` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::get_unwrap)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_unwrap [INFO] [stderr] [INFO] [stderr] warning: called `.get().unwrap()` on a HashMap. Using `[]` is more clear and more concise [INFO] [stderr] --> src/trainer.rs:114:31 [INFO] [stderr] | [INFO] [stderr] 114 | .any(|(k, v)| unigrams.get(k).unwrap() != v) [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `&unigrams[k]` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_unwrap [INFO] [stderr] [INFO] [stderr] warning: methods called `to_*` usually take self by reference; consider choosing a less ambiguous name [INFO] [stderr] --> src/trainer.rs:210:23 [INFO] [stderr] | [INFO] [stderr] 210 | fn to_string_from(self, normalized: &str) -> String { [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: length comparison to zero [INFO] [stderr] --> src/trainer.rs:220:12 [INFO] [stderr] | [INFO] [stderr] 220 | && sentence.trim().len() > 0 [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `!sentence.trim().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: use of deprecated item 'failure::Error::causes': please use the 'iter_chain()' method instead [INFO] [stderr] --> src/main.rs:149:26 [INFO] [stderr] | [INFO] [stderr] 149 | for failure in error.causes() { [INFO] [stderr] | ^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(deprecated)] on by default [INFO] [stderr] [INFO] [stderr] warning: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` [INFO] [stderr] --> src/main.rs:75:9 [INFO] [stderr] | [INFO] [stderr] 75 | / match do_train(input_filenames, output_filename) { [INFO] [stderr] 76 | | Err(error) => print_error(error), [INFO] [stderr] 77 | | Ok(_) => {} [INFO] [stderr] 78 | | } [INFO] [stderr] | |_________^ help: try this: `if let Err(error) = do_train(input_filenames, output_filename) { print_error(error) }` [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] [INFO] [stderr] warning: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` [INFO] [stderr] --> src/main.rs:87:9 [INFO] [stderr] | [INFO] [stderr] 87 | / match do_truecase(model_filename, input_filename, output_filename) { [INFO] [stderr] 88 | | Err(error) => print_error(error), [INFO] [stderr] 89 | | Ok(_) => {} [INFO] [stderr] 90 | | }; [INFO] [stderr] | |_________^ help: try this: `if let Err(error) = do_truecase(model_filename, input_filename, output_filename) { print_error(error) }` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match [INFO] [stderr] [INFO] [stderr] Finished dev [unoptimized + debuginfo] target(s) in 12.10s [INFO] running `"docker" "inspect" "d00582ff5cf0131bc035bb9e31a0742b86796cdc2cb00ccc678d8cd2b002562a"` [INFO] running `"docker" "rm" "-f" "d00582ff5cf0131bc035bb9e31a0742b86796cdc2cb00ccc678d8cd2b002562a"` [INFO] [stdout] d00582ff5cf0131bc035bb9e31a0742b86796cdc2cb00ccc678d8cd2b002562a