commit 2fc8ee279b55d1da274fc17ef6ab73efcdd1c206
parent 7a353b8e7e4bfa7b9f9ad26d33f9863489e4b84c
Author: Roberto E. Vargas Caballero <k0ga@shike2.com>
Date: Tue, 15 Apr 2014 10:58:47 +0200
Fix integer parse
While the scanner is parsing it uses yybuf, no yytext, so
atoi must be done over yybuf.
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lex.c b/lex.c
@@ -41,7 +41,7 @@ type:
sym = install("", NS_IDEN);
sym->type = inttype;
- sym->u.i = atoi(yytext);
+ sym->u.i = atoi(yybuf);
yynlval.sym = sym;
return CONSTANT;
}