[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Redefining the literal string associated to the YYerror symbol
From: |
Daniele Nicolodi |
Subject: |
Redefining the literal string associated to the YYerror symbol |
Date: |
Wed, 17 Jun 2020 23:57:14 -0600 |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:68.0) Gecko/20100101 Thunderbird/68.9.0 |
Hello,
in Bison 3.6 is it possible to redefine the literal string associated to
the YYerror symbol (and to the YYEOF, YYUNDEF ones, although I don't
have immediate need for this)?
Doing it in the naive way:
%token YYerror "ERROR"
results in a warning:
warning: symbol YYerror given more than one literal string [-Wother]
180 | %token YYerror "ERROR"
| ^~~~~~~
and in the literal string not being updated.
Thank you.
Cheers,
Dan
- Redefining the literal string associated to the YYerror symbol,
Daniele Nicolodi <=