lexer: Putback non-numerical token in number scanning
Signed-off-by: Ian Moffett <ian@mirocom.org>
This commit is contained in:
@@ -386,6 +386,7 @@ lexer_scan_num(struct rifle_state *state, int lc, struct token *tok)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!isxdigit(c) && c != '_') {
|
if (!isxdigit(c) && c != '_') {
|
||||||
|
lexer_putback(state, c);
|
||||||
buf[buf_ind] = '\0';
|
buf[buf_ind] = '\0';
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user