Lex integers as unsigned long instead of signed int, fixing the immediate test.
authorEric Anholt <eric@anholt.net>
Thu, 31 Aug 2006 23:19:08 +0000 (16:19 -0700)
committerDamien Lespiau <damien.lespiau@intel.com>
Mon, 4 Mar 2013 15:54:24 +0000 (15:54 +0000)
assembler/src/lex.l

index 1ed2d9e..e9f865c 100644 (file)
@@ -294,7 +294,7 @@ int saved_state = INITIAL;
 }
 
 [0-9]* {
-       yylval.integer = atoi(yytext);
+       yylval.integer = strtoul(yytext, NULL, 10);
        return INTEGER;
 }