File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -93,7 +93,7 @@ impl<'a> Formatter<'a> {
93
93
for c in s. chars ( ) {
94
94
match c {
95
95
'\n' => has_newline = true ,
96
- '\r' | '\t' | '\u{0020}' ... '\u{FFFF}' => { }
96
+ '\r' | '\t' | '\u{0020}' ..= '\u{FFFF}' => { }
97
97
_ => has_nonprintable = true ,
98
98
}
99
99
}
@@ -107,7 +107,7 @@ impl<'a> Formatter<'a> {
107
107
'\t' => self . write ( r"\t" ) ,
108
108
'"' => self . write ( "\\ \" " ) ,
109
109
'\\' => self . write ( r"\\" ) ,
110
- '\u{0020}' ... '\u{FFFF}' => self . buf . push ( c) ,
110
+ '\u{0020}' ..= '\u{FFFF}' => self . buf . push ( c) ,
111
111
_ => write ! ( & mut self . buf, "\\ u{:04}" , c as u32 ) . unwrap ( ) ,
112
112
}
113
113
}
Original file line number Diff line number Diff line change @@ -169,10 +169,10 @@ impl<'a> TokenStream<'a> {
169
169
)
170
170
}
171
171
}
172
- '_' | 'a' ... 'z' | 'A' ... 'Z' => {
172
+ '_' | 'a' ..= 'z' | 'A' ..= 'Z' => {
173
173
while let Some ( ( idx, cur_char) ) = iter. next ( ) {
174
174
match cur_char {
175
- '_' | 'a' ... 'z' | 'A' ... 'Z' | '0' ... '9' => continue ,
175
+ '_' | 'a' ..= 'z' | 'A' ..= 'Z' | '0' ..= '9' => continue ,
176
176
_ => {
177
177
self . position . column += idx;
178
178
self . off += idx;
@@ -186,7 +186,7 @@ impl<'a> TokenStream<'a> {
186
186
187
187
Ok ( ( Name , len) )
188
188
}
189
- '-' | '0' ... '9' => {
189
+ '-' | '0' ..= '9' => {
190
190
let mut exponent = None ;
191
191
let mut real = None ;
192
192
let len = loop {
You can’t perform that action at this time.
0 commit comments