[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: LAC (lookahead correction) for syntax error handling
From: |
Joel E. Denny |
Subject: |
Re: LAC (lookahead correction) for syntax error handling |
Date: |
Sat, 29 Jan 2011 11:08:49 -0500 (EST) |
User-agent: |
Alpine 2.00 (DEB 1167 2008-08-23) |
On Wed, 26 Jan 2011, Akim Demaille wrote:
> > Perhaps most notably, LAC fixes the expected token list in syntax
> > error messages produced by %error-verbose. See NEWS for more details.
>
> This is nice work. I have not read it in all the details, but it is, as
> usual, well commented, documented, and tested.
By the way, thanks!
Of course, if you (or anyone) have a chance to try out LAC in your own
projects, I'd be interested in hearing of your experiences with it. Keep
in mind that's it's useful for LALR, IELR, and canonical LR.
Also, there is another problem with syntax error messages that we've
discussed before and that LAC might expose further. Sometimes, when it
seems LAC should correct the expected token list in a syntax error
message, both the unexpected token and the expected token list are simply
dropped. The problem here is that, for the sake of translation, the
expected token list is limited to 4 tokens. I'm thinking the user ought
to be able to control the limit, possibly removing the limit entirely.
Surely we can find some way to handle the translation issues.
In any case, unless there's a simple fix, I don't expect to address this
in 2.5, but I should probably document it. NEWS should probably at least
mention that there are some minor caveats to read about in the manual.