bison-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: document new features of parse.error


From: Akim Demaille
Subject: Re: document new features of parse.error
Date: Tue, 28 Jan 2020 07:20:25 +0100

Hi Adrian,

> Le 27 janv. 2020 à 10:19, Adrian Vogelsgesang <address@hidden> a écrit :
> 
> Hi Akim,
> 
> do you think it makes sense to deprecate `verbose` already with the 
> introduction of `detailed`?
> As far as I see it, there is no good reason to use `verbose` over `detailed`, 
> or am I missing something?

It's too soon to declare verbose obsolete, and anyway we don't yet provide an 
alternative for people who depend on yytname for their scanner 
(https://www.gnu.org/software/bison/manual/html_node/Tokens-from-Literals.html#Tokens-from-Literals).
  On purpose I made this feature impossible to use with custom/detailed because 
string aliases are not fit to define the tokens.  So they clearly cannot move 
to 'detailed' just yet (without sacrificing their scanner implementation).

When a true alternative is offered, then we might deprecate verbose.

That being said, I really think we should stop depending on the locale when 
emitting yytname.  It should only escape " and \ IMHO, and not touch the rest.  
Let's address this in 3.6 too.

Also, I have proposed, to help people who use yytname for their scanner, to 
generate a CSV file with facts about the tokens (numbers, strings, etc.).  I 
think that this would be useful, especially for those, like Rici, that run 
tools to generate part of their scanner/parser, but received no answer.


> Also:
>> +Control the generation syntax error messages. @xref{Error Reporting}.

Thanks!


Do you plan to port these features to lalr1.cc?




reply via email to

[Prev in Thread] Current Thread [Next in Thread]