%{ #include <stdio.h> %} %% abc { printf("ABC"); } .|\n { printf("%s", yytext); } %% int main() { yylex(); return 0; }
abc123abcabcxyz
Standard output is empty
ERROR: /home/h7YGbQ/prog:15:0: Syntax error: Unexpected end of file ERROR: '$runtoplevel'/0: Undefined procedure: program/0 Exception: (3) program ? EOF: exit