mirror of
https://github.com/rust-lang/rust-analyzer
synced 2024-12-25 20:43:21 +00:00
Fix typo
This commit is contained in:
parent
96c3ff1c57
commit
a94c564ad0
1 changed files with 1 additions and 2 deletions
|
@ -333,13 +333,12 @@ impl ast::Literal {
|
||||||
|
|
||||||
match token.kind() {
|
match token.kind() {
|
||||||
INT_NUMBER => {
|
INT_NUMBER => {
|
||||||
// FYI: there was a bug here previously, thus an if statement bellow is necessary.
|
// FYI: there was a bug here previously, thus the if statement below is necessary.
|
||||||
// The lexer treats e.g. `1f64` as an integer literal. See
|
// The lexer treats e.g. `1f64` as an integer literal. See
|
||||||
// https://github.com/rust-analyzer/rust-analyzer/issues/1592
|
// https://github.com/rust-analyzer/rust-analyzer/issues/1592
|
||||||
// and the comments on the linked PR.
|
// and the comments on the linked PR.
|
||||||
|
|
||||||
let text = token.text();
|
let text = token.text();
|
||||||
|
|
||||||
if let suffix @ Some(_) = Self::find_suffix(&text, &FLOAT_SUFFIXES) {
|
if let suffix @ Some(_) = Self::find_suffix(&text, &FLOAT_SUFFIXES) {
|
||||||
LiteralKind::FloatNumber { suffix }
|
LiteralKind::FloatNumber { suffix }
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue