diff options
author | Akshay <[email protected]> | 2021-11-28 13:55:36 +0000 |
---|---|---|
committer | Akshay <[email protected]> | 2021-11-28 13:55:36 +0000 |
commit | 1079486539d44b2e70c623fb4948d6e0b9b11812 (patch) | |
tree | 7dc80cbfb44d31b8fd63955a290e687a32adbec1 /bin | |
parent | cef2deec580acda72e0575b47b6415e5421736a7 (diff) |
remove lint: unquoted_splice
Diffstat (limited to 'bin')
-rw-r--r-- | bin/src/config.rs | 4 | ||||
-rw-r--r-- | bin/src/fix.rs | 2 | ||||
-rw-r--r-- | bin/src/fix/all.rs | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/bin/src/config.rs b/bin/src/config.rs index b6310e6..572ddde 100644 --- a/bin/src/config.rs +++ b/bin/src/config.rs | |||
@@ -334,11 +334,11 @@ fn vfs(files: Vec<PathBuf>) -> Result<ReadOnlyVfs, ConfigErr> { | |||
334 | Ok(vfs) | 334 | Ok(vfs) |
335 | } | 335 | } |
336 | 336 | ||
337 | fn lints(conf_path: &PathBuf) -> Result<LintMap, ConfigErr> { | 337 | fn lints(conf_path: &Path) -> Result<LintMap, ConfigErr> { |
338 | let config_file = ConfFile::discover(conf_path)?; | 338 | let config_file = ConfFile::discover(conf_path)?; |
339 | Ok(utils::lint_map_of( | 339 | Ok(utils::lint_map_of( |
340 | (&*LINTS) | 340 | (&*LINTS) |
341 | .into_iter() | 341 | .iter() |
342 | .filter(|l| !config_file.disabled.iter().any(|check| check == l.name())) | 342 | .filter(|l| !config_file.disabled.iter().any(|check| check == l.name())) |
343 | .cloned() | 343 | .cloned() |
344 | .collect::<Vec<_>>() | 344 | .collect::<Vec<_>>() |
diff --git a/bin/src/fix.rs b/bin/src/fix.rs index 4268567..a035379 100644 --- a/bin/src/fix.rs +++ b/bin/src/fix.rs | |||
@@ -100,7 +100,7 @@ pub mod main { | |||
100 | text_diff | 100 | text_diff |
101 | .unified_diff() | 101 | .unified_diff() |
102 | .context_radius(4) | 102 | .context_radius(4) |
103 | .header(&old_file, &new_file) | 103 | .header(old_file, &new_file) |
104 | ); | 104 | ); |
105 | } | 105 | } |
106 | (FixOut::Stream, single_result) => { | 106 | (FixOut::Stream, single_result) => { |
diff --git a/bin/src/fix/all.rs b/bin/src/fix/all.rs index bbc39e8..7e51d16 100644 --- a/bin/src/fix/all.rs +++ b/bin/src/fix/all.rs | |||
@@ -57,7 +57,7 @@ fn reorder(mut reports: Vec<Report>) -> Vec<Report> { | |||
57 | impl<'a> Iterator for FixResult<'a> { | 57 | impl<'a> Iterator for FixResult<'a> { |
58 | type Item = FixResult<'a>; | 58 | type Item = FixResult<'a>; |
59 | fn next(&mut self) -> Option<Self::Item> { | 59 | fn next(&mut self) -> Option<Self::Item> { |
60 | let all_reports = collect_fixes(&self.src, &self.lints).ok()?; | 60 | let all_reports = collect_fixes(&self.src, self.lints).ok()?; |
61 | if all_reports.is_empty() { | 61 | if all_reports.is_empty() { |
62 | return None; | 62 | return None; |
63 | } | 63 | } |