[antlr-interest] Any ready smart recovering from parsing errors?

Matthew Ford Matthew.Ford at forward.com.au
Mon Dec 1 14:41:09 PST 2003


I have an error recovery scheme that skips forward to the next ;
I used it for a telnet server accepting commands.  But I think you need
something more advanced.
matthew

----- Original Message ----- 
From: "Anton" <anton.safonov at refactorit.com>
To: <antlr-interest at yahoogroups.com>
Sent: Tuesday, December 02, 2003 4:27 AM
Subject: [antlr-interest] Any ready smart recovering from parsing errors?


> Hi, All!
>
> Does anyone has any ready techniques of parsing errors recovering of
> the same strength as some time earlier mentioned Cocktail Compiler
> Toolbox?
>
> What I need, is to recover as much of the code as possible without
> loosing any single token (ok, it is a super goal, but it would be
> really great).
> E.g. it should be able to parse such code with reporting just 2 minor
> problems:
> public void method() {
>   if (x < y
>     super.method()
>   }
> }
>
> It was said, that it is possible to port the code of that Cocktail
> compiler into Antlr? Has anyone tried to do it actually? At least
> anything?
>
> As an alternative, I've seen also some notes about FOLLOW and FIRST
> bit sets, which generally allow "as much as Cocktail does, but with
> even greater flexibility". First of all, can not find these sets :(
> And the second, it is really great to know that "it is possible", but
> it would be even better to see it working! Any real examples
> (especially for java.g)? Or good detailed descriptions of how to do
> it?
>
> I understand, that I can sit, take a month and get it working. The
> problem is usual...
>
> Hopefully waiting for your suggestions,
> Anton
>
>
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>


 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/ 




More information about the antlr-interest mailing list