add error_flag = true in main.c/yyerror