Lexical numbers may be signed.

This commit is contained in:
steve 2001-03-20 02:45:25 +00:00
parent e8518c5056
commit 8118203766
2 changed files with 3 additions and 3 deletions

View File

@ -40,11 +40,11 @@
return T_INSTR; }
[0-9][0-9]* {
yylval.numb = strtoul(yytext, 0, 0);
yylval.numb = strtol(yytext, 0, 0);
return T_NUMBER; }
"0x"[0-9a-fA-F]+ {
yylval.numb = strtoul(yytext, 0, 0);
yylval.numb = strtol(yytext, 0, 0);
return T_NUMBER; }

View File

@ -15,7 +15,7 @@ extern FILE*yyin;
%union {
char*text;
unsigned long numb;
long numb;
struct textv_s textv;
comp_operands_t opa;