1
Fork 0

remove redundant closures (clippy::redundant_closure)

This commit is contained in:
Matthias Krüger 2020-12-30 04:19:09 +01:00
parent 18cb4ad3b9
commit e2272cdffc
11 changed files with 42 additions and 45 deletions

View file

@ -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();
}
}