aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_syntax/src
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_syntax/src')
-rw-r--r--crates/ra_syntax/src/parsing/lexer/numbers.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/ra_syntax/src/parsing/lexer/numbers.rs b/crates/ra_syntax/src/parsing/lexer/numbers.rs
index 7f6abe1d5..874fb8b32 100644
--- a/crates/ra_syntax/src/parsing/lexer/numbers.rs
+++ b/crates/ra_syntax/src/parsing/lexer/numbers.rs
@@ -16,7 +16,7 @@ pub(crate) fn scan_number(c: char, ptr: &mut Ptr) -> SyntaxKind {
16 ptr.bump(); 16 ptr.bump();
17 scan_digits(ptr, true); 17 scan_digits(ptr, true);
18 } 18 }
19 '0'...'9' | '_' | '.' | 'e' | 'E' => { 19 '0'..='9' | '_' | '.' | 'e' | 'E' => {
20 scan_digits(ptr, true); 20 scan_digits(ptr, true);
21 } 21 }
22 _ => return INT_NUMBER, 22 _ => return INT_NUMBER,
@@ -47,10 +47,10 @@ pub(crate) fn scan_number(c: char, ptr: &mut Ptr) -> SyntaxKind {
47fn scan_digits(ptr: &mut Ptr, allow_hex: bool) { 47fn scan_digits(ptr: &mut Ptr, allow_hex: bool) {
48 while let Some(c) = ptr.current() { 48 while let Some(c) = ptr.current() {
49 match c { 49 match c {
50 '_' | '0'...'9' => { 50 '_' | '0'..='9' => {
51 ptr.bump(); 51 ptr.bump();
52 } 52 }
53 'a'...'f' | 'A'...'F' if allow_hex => { 53 'a'..='f' | 'A'..='F' if allow_hex => {
54 ptr.bump(); 54 ptr.bump();
55 } 55 }
56 _ => return, 56 _ => return,