Commit e4d064e5 authored by zygzagZ's avatar zygzagZ

Fix wymagania techniczne

parent 09a934d5
...@@ -96,6 +96,8 @@ int main(int argc, char ** argv) ...@@ -96,6 +96,8 @@ int main(int argc, char ** argv)
ll << out; ll << out;
ll.close(); ll.close();
std::cerr << "OK" << endl;
Compiler::externalCommand(file); Compiler::externalCommand(file);
} catch (ParseError const &e) { } catch (ParseError const &e) {
std::cerr << "ERROR" << endl; std::cerr << "ERROR" << endl;
...@@ -121,6 +123,5 @@ int main(int argc, char ** argv) ...@@ -121,6 +123,5 @@ int main(int argc, char ** argv)
} }
return 1; return 1;
} }
std::cerr << "OK" << endl;
} }
...@@ -88,7 +88,7 @@ int yywrap(void) ...@@ -88,7 +88,7 @@ int yywrap(void)
void yyerror(const char *str) void yyerror(const char *str)
{ {
extern char *yytext; extern char *yytext;
fprintf(stderr,"error: line %d: %s at %s\n", fprintf(stderr,"ERROR\nerror: line %d: %s at %s\n",
yy_mylinenumber, str, yytext); yy_mylinenumber, str, yytext);
} }
...@@ -1019,7 +1019,7 @@ enum { YYENOMEM = -2 }; ...@@ -1019,7 +1019,7 @@ enum { YYENOMEM = -2 };
} \ } \
else \ else \
{ \ { \
yyerror (YY_("syntax error: cannot back up")); \ yyerror (YY_("ERROR\nsyntax error: cannot back up")); \
YYERROR; \ YYERROR; \
} \ } \
while (0) while (0)
...@@ -2027,7 +2027,7 @@ yyerrlab: ...@@ -2027,7 +2027,7 @@ yyerrlab:
} }
else else
{ {
yydestruct ("Error: discarding", yydestruct ("ERROR\nError: discarding",
yytoken, &yylval); yytoken, &yylval);
yychar = YYEMPTY; yychar = YYEMPTY;
} }
...@@ -2082,7 +2082,7 @@ yyerrlab1: ...@@ -2082,7 +2082,7 @@ yyerrlab1:
YYABORT; YYABORT;
yydestruct ("Error: popping", yydestruct ("ERROR\nError: popping",
YY_ACCESSING_SYMBOL (yystate), yyvsp); YY_ACCESSING_SYMBOL (yystate), yyvsp);
YYPOPSTACK (1); YYPOPSTACK (1);
yystate = *yyssp; yystate = *yyssp;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment