diff --git a/tools/rustdoc/rustdoc_test_writer.rs b/tools/rustdoc/rustdoc_test_writer.rs index 7bdb2ca884..43b12943a8 100644 --- a/tools/rustdoc/rustdoc_test_writer.rs +++ b/tools/rustdoc/rustdoc_test_writer.rs @@ -30,7 +30,7 @@ struct Options { /// Parse command line arguments fn parse_args() -> Options { - let args: Vec = env::args().into_iter().collect(); + let args: Vec = env::args().collect(); let (writer_args, action_args) = { let split = args .iter() @@ -273,7 +273,6 @@ fn main() { let opt = expand_params_file(opt); let env: BTreeMap = env::vars() - .into_iter() .filter(|(key, _)| opt.env_keys.iter().any(|k| k == key)) .collect(); diff --git a/tools/rustfmt/src/lib.rs b/tools/rustfmt/src/lib.rs index 5ab0ada95a..5cd05f20f3 100644 --- a/tools/rustfmt/src/lib.rs +++ b/tools/rustfmt/src/lib.rs @@ -62,7 +62,6 @@ pub fn parse_rustfmt_manifest(manifest: &Path) -> RustfmtManifest { let mut lines: Vec = content .split('\n') - .into_iter() .filter(|s| !s.is_empty()) .map(|s| s.to_owned()) .collect();