I have a parser with me created from yacc / lex. It works great for all the rules that I set, except in one case.
If the file is empty, which the parser parses, it gives an error. I want to add a rule so that it does not throw an error when the file is empty. I have not added any checks for this in any of the .l / .y files.
How can this be done with YACC / LEX?
Thanks in advance!
source
share