diff --git a/Monicelli.ll b/Monicelli.ll index f139028..5e9545c 100644 --- a/Monicelli.ll +++ b/Monicelli.ll @@ -17,7 +17,7 @@ CHAR [a-zA-Z_] %x shift %% -("\r\n"|"\n") { +("\r\n"|"\n") { lineNumber += 1; } @@ -153,7 +153,7 @@ CHAR [a-zA-Z_] return CASE_END; } -[ \t\f\v] {} +[ \t\f\v] {} {CHAR}({DIGIT}|{CHAR})* { yylval.strval = strdup(yytext); @@ -165,7 +165,7 @@ CHAR [a-zA-Z_] return NUMBER; } -. { +. { yyerror("Unexpected token"); return -1; };