[Menhir-list] Error reporting

Francois Pottier Francois.Pottier at inria.fr
Thu Feb 10 13:19:45 CET 2011


Hello,

On Thu, Feb 10, 2011 at 12:18:56PM +0100, Rémi Dewitte wrote:
> I would like to give a more detailed error message when the user submits a
> script with a syntax error. Something like :
> Got token COMMA expected one of SEMICOLON, LPAREN.
> 
> I have found it pretty easy to implement the Got token part from the lexer,
> but I can't find a way to get more info from menhir parser. Do you have an
> idea ?

At the moment, there is no way to obtain the set of tokens that would not have
caused an error.

In principle, it should be possible to add this feature under some form. I
will add this to the feature wish list, but don't hold your breath -- we
don't have time to actively work on Menhir at the moment.

Best regards,

-- 
François Pottier
Francois.Pottier at inria.fr
http://gallium.inria.fr/~fpottier/



More information about the Menhir-list mailing list