[antlr-interest] Error recovery contortion
Ric Klaren
ric.klaren at gmail.com
Tue Dec 7 12:24:40 PST 2004
On Tue, 7 Dec 2004 11:40:09 -0800 (PST), Paul J. Lucas
<pauljlucas at mac.com> wrote:
> On Tue, 7 Dec 2004, Ric Klaren wrote:
> > Might be an idea to also move the reportError into recover then, saves some
> > code.
>
> No, because if I override recover() I don't want to have to
> remember to call reportError().
>
> Reporting errors and recovering from them are two seperate
> things and should be handled as such.
Good point, although it's a bit of a matter of taste, could also make
an handleError that calls reportError and recover. Only safe is in
codesize, speed wise it wouldn't matter much I guess. Either way is
fine with me ;)
Cheers,
Ric
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/antlr-interest/
<*> To unsubscribe from this group, send an email to:
antlr-interest-unsubscribe at yahoogroups.com
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
More information about the antlr-interest
mailing list