diff options
| author | Quentin Carbonneaux | 2015-03-05 15:33:07 -0500 |
|---|---|---|
| committer | Quentin Carbonneaux | 2015-03-05 15:33:07 -0500 |
| commit | 8a59c32946014165fa7b1843713537dc38d14bb0 (patch) | |
| tree | e0e325cf04ec5d49c71bd57e3d2c15a8661d3b2d | |
| parent | 6b619da0bf69bc50f67a64bd497c5fd00747ccaf (diff) | |
more correct C code
| -rw-r--r-- | act.y | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -6,7 +6,7 @@ start: 'x' foo 'y'; foo: { puts("act!"); }; %% -int yyerror() { puts("oops, yacc error!"); } +int yyerror() { puts("oops, yacc error!"); return 0; } int yylex() { int c = getchar(); printf("lex %d\n", c); return c==EOF?0:c; } -int main() { yyparse(); } +int main() { return yyparse(); } |
