Skip to content

Commit

Permalink
Change deprecated range syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
kornelski authored and seanmonstar committed Dec 16, 2019
1 parent d5c0360 commit 938484d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion mime-parse/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ impl fmt::Debug for Byte {
b'\t' => f.write_str("'\\t'"),
b'\\' => f.write_str("'\\'"),
b'\0' => f.write_str("'\\0'"),
0x20...0x7f => write!(f, "'{}'", self.0 as char),
0x20..=0x7f => write!(f, "'{}'", self.0 as char),
_ => write!(f, "'\\x{:02x}'", self.0),
}
}
Expand Down
6 changes: 3 additions & 3 deletions mime-parse/src/rfc7231.rs
Original file line number Diff line number Diff line change
Expand Up @@ -333,9 +333,9 @@ mod tests {
for (i, &valid) in super::TOKEN_MAP.iter().enumerate() {
let i = i as u8;
let should = match i {
b'a'...b'z' |
b'A'...b'Z' |
b'0'...b'9' |
b'a'..=b'z' |
b'A'..=b'Z' |
b'0'..=b'9' |
b'!' |
b'#' |
b'$' |
Expand Down

0 comments on commit 938484d

Please sign in to comment.