use char instead of &str for single char patterns
This commit is contained in:
parent
a8437cf213
commit
7c84ba1124
30 changed files with 44 additions and 44 deletions
|
@ -2396,9 +2396,9 @@ impl<B: BufRead> Iterator for Lines<B> {
|
|||
match self.buf.read_line(&mut buf) {
|
||||
Ok(0) => None,
|
||||
Ok(_n) => {
|
||||
if buf.ends_with("\n") {
|
||||
if buf.ends_with('\n') {
|
||||
buf.pop();
|
||||
if buf.ends_with("\r") {
|
||||
if buf.ends_with('\r') {
|
||||
buf.pop();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue