Skip to content

Commit 8a02512

Browse files
committed
Auto merge of #3699 - matthiaskrgr:itertools, r=oli-obk
dependencies: update itertools from 0.7 to 0.8
2 parents aca1b81 + 873fe11 commit 8a02512

File tree

3 files changed

+17
-12
lines changed

3 files changed

+17
-12
lines changed

clippy_dev/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ edition = "2018"
66

77
[dependencies]
88
clap = "~2.32"
9-
itertools = "0.7"
9+
itertools = "0.8"
1010
regex = "1"
1111
lazy_static = "1.0"
1212
walkdir = "2"

clippy_dev/src/lib.rs

+15-10
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,7 @@ pub fn gen_lint_group_list(lints: Vec<Lint>) -> Vec<String> {
8282
}
8383
})
8484
.sorted()
85+
.collect::<Vec<String>>()
8586
}
8687

8788
/// Generates the `pub mod module_name` list in `clippy_lints/src/lib.rs`.
@@ -98,6 +99,7 @@ pub fn gen_modules_list(lints: Vec<Lint>) -> Vec<String> {
9899
.unique()
99100
.map(|module| format!("pub mod {};", module))
100101
.sorted()
102+
.collect::<Vec<String>>()
101103
}
102104

103105
/// Generates the list of lint links at the bottom of the README
@@ -118,17 +120,20 @@ pub fn gen_changelog_lint_list(lints: Vec<Lint>) -> Vec<String> {
118120

119121
/// Generates the `register_removed` code in `./clippy_lints/src/lib.rs`.
120122
pub fn gen_deprecated(lints: &[Lint]) -> Vec<String> {
121-
itertools::flatten(lints.iter().filter_map(|l| {
122-
l.clone().deprecation.and_then(|depr_text| {
123-
Some(vec![
124-
" store.register_removed(".to_string(),
125-
format!(" \"{}\",", l.name),
126-
format!(" \"{}\",", depr_text),
127-
" );".to_string(),
128-
])
123+
lints
124+
.iter()
125+
.filter_map(|l| {
126+
l.clone().deprecation.and_then(|depr_text| {
127+
Some(vec![
128+
" store.register_removed(".to_string(),
129+
format!(" \"{}\",", l.name),
130+
format!(" \"{}\",", depr_text),
131+
" );".to_string(),
132+
])
133+
})
129134
})
130-
}))
131-
.collect()
135+
.flatten()
136+
.collect::<Vec<String>>()
132137
}
133138

134139
/// Gathers all files in `src/clippy_lints` and gathers all lints inside

clippy_lints/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ edition = "2018"
1818

1919
[dependencies]
2020
cargo_metadata = "0.6.2"
21-
itertools = "0.7"
21+
itertools = "0.8"
2222
lazy_static = "1.0.2"
2323
matches = "0.1.7"
2424
quine-mc_cluskey = "0.2.2"

0 commit comments

Comments
 (0)