[antlr-interest] Query regarding Error handling in Antlr parser
Martin Probst
mail at martin-probst.com
Mon Feb 27 09:51:28 PST 2006
> I see that all the functions in the parser code handle execeptions by
> calling restore(). This does not work very well for the application I am
> working on. There is no way to catch an error as no exceptions are thrown
> and there is no return value that indicates that there was an error. This
> results in a core dump in my application in case of an invalid input.
> I have had to manually change the auto generated parser to throw exceptions
> instead of calling restore.
> Is there a way to specify this in the grammar file?
defaultErrorHandler = false;
Martin
More information about the antlr-interest
mailing list