mirror of
https://github.com/sheumann/hush.git
synced 2024-12-27 16:31:24 +00:00
awk: support hex constants
This commit is contained in:
parent
d66aa3c701
commit
996a61475a
@ -973,6 +973,11 @@ static uint32_t next_token(uint32_t expected)
|
||||
|
||||
} else if (*p == '.' || isdigit(*p)) {
|
||||
/* it's a number */
|
||||
#if ENABLE_DESKTOP
|
||||
if (p[0] == '0' && (p[1] | 0x20) == 'x')
|
||||
t_double = strtoll(p, &p, 0);
|
||||
else
|
||||
#endif
|
||||
t_double = strtod(p, &p);
|
||||
if (*p == '.')
|
||||
syntax_error(EMSG_UNEXP_TOKEN);
|
||||
|
Loading…
Reference in New Issue
Block a user