mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
v2: fix bug in scanner, introduced in da9b639
(_ in num literals)
This commit is contained in:
parent
da9b6394e8
commit
543e8dc78a
@ -177,7 +177,7 @@ fn (s mut Scanner) ident_oct_number() string {
|
|||||||
fn (s mut Scanner) ident_dec_number() string {
|
fn (s mut Scanner) ident_dec_number() string {
|
||||||
start_pos := s.pos
|
start_pos := s.pos
|
||||||
// scan integer part
|
// scan integer part
|
||||||
for s.pos < s.text.len && (s.text[s.pos].is_digit() || s.text[s.pos] != num_sep) {
|
for s.pos < s.text.len && (s.text[s.pos].is_digit() || s.text[s.pos] == num_sep) {
|
||||||
s.pos++
|
s.pos++
|
||||||
}
|
}
|
||||||
// e.g. 1..9
|
// e.g. 1..9
|
||||||
|
Loading…
Reference in New Issue
Block a user