Auto merge of #80499 - matthiaskrgr:red_clos, r=estebank
remove redundant closures (clippy::redundant_closure)
This commit is contained in:
commit
fc9944fe84
10 changed files with 41 additions and 44 deletions
|
@ -92,7 +92,7 @@ crate fn matches_codepattern(a: &str, b: &str) -> bool {
|
|||
|
||||
/// Advances the given peekable `Iterator` until it reaches a non-whitespace character.
|
||||
fn scan_for_non_ws_or_end<I: Iterator<Item = char>>(iter: &mut Peekable<I>) {
|
||||
while iter.peek().copied().map(|c| rustc_lexer::is_whitespace(c)) == Some(true) {
|
||||
while iter.peek().copied().map(rustc_lexer::is_whitespace) == Some(true) {
|
||||
iter.next();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue