fork download
  1. %{
  2. #include "y.tab.h"
  3. %}
  4.  
  5. %%
  6. "for" { return FOR; }
  7. "(" { return LPAREN; }
  8. ")" { return RPAREN; }
  9. ";" { return SEMICOLON; }
  10. [a-zA-Z_][a-zA-Z0-9_]* { return ID; }
  11. [0-9]+ { return NUM; }
  12. . { return yytext[0]; }
  13. \n ;
  14. %%
  15.  
  16. int yywrap() { return 1; }
  17.  
Success #stdin #stdout #stderr 0.02s 6848KB
stdin
Standard input is empty
stdout
Standard output is empty
stderr
ERROR: /home/a57hFo/prog:2:1: Syntax error: Operator expected
ERROR: /home/a57hFo/prog:16:26: Syntax error: Unexpected end of file
ERROR: '$runtoplevel'/0: Undefined procedure: program/0
   Exception: (3) program ? EOF: exit