check if a char is whitespace instead of explicitly checking against a few chars, ignore Cargo.lock
This commit is contained in:
parent
b7e4954f00
commit
87b68b79f8
1
.gitignore
vendored
1
.gitignore
vendored
@ -1 +1,2 @@
|
|||||||
target/
|
target/
|
||||||
|
Cargo.lock
|
||||||
|
@ -463,7 +463,7 @@ impl<'a> Iterator for TokenIterator<'a> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
' ' | '\n' | '\r' => (),
|
_x if _x.is_whitespace() => (),
|
||||||
_ => return Some(Token::LexErr(LexError::UnexpectedChar)),
|
_ => return Some(Token::LexErr(LexError::UnexpectedChar)),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user