* src/reader.c (readgram): Make sure rules for mid-rule actions

have a lineno equal to that of their host rule.
Reported by Hans Aberg.
* tests/regression.at (Rule Line Numbers): New.
This commit is contained in:
Akim Demaille
2001-11-26 15:24:06 +00:00
parent 6fedd4d1d6
commit 674fd9acbc
12 changed files with 379 additions and 228 deletions

View File

@@ -6,7 +6,7 @@
msgid ""
msgstr ""
"Project-Id-Version: GNU bison 1.30c\n"
"POT-Creation-Date: 2001-11-23 15:16+0100\n"
"POT-Creation-Date: 2001-11-26 16:23+0100\n"
"PO-Revision-Date: 2001-11-19 12:00-0500\n"
"Last-Translator: Michel Robitaille <robitail@IRO.UMontreal.CA>\n"
"Language-Team: French <traduc@traduc.org>\n"
@@ -27,7 +27,7 @@ msgstr "Erreur syst
msgid "warning: "
msgstr "AVERTISSEMENT: "
#: src/complain.c:238 src/complain.c:279
#: src/complain.c:238
msgid "fatal error: "
msgstr "erreur fatale: "
@@ -72,37 +72,37 @@ msgstr "L'
#. If invoked with `--yacc', use the output format specified by
#. POSIX.
#: src/conflicts.c:460
#: src/conflicts.c:470
msgid "conflicts: "
msgstr "conflits: "
#: src/conflicts.c:462
#: src/conflicts.c:472
#, c-format
msgid " %d shift/reduce"
msgstr " %d décalage/réduction"
#: src/conflicts.c:466
#: src/conflicts.c:476
#, c-format
msgid " %d reduce/reduce"
msgstr " %d réduction/réduction"
#: src/conflicts.c:471 src/reduce.c:493
#: src/conflicts.c:481 src/reduce.c:493
#, c-format
msgid "%s contains "
msgstr "%s contient "
#: src/conflicts.c:480
#: src/conflicts.c:488
#, fuzzy, c-format
msgid "expected %d shift/reduce conflict\n"
msgid_plural "expected %d shift/reduce conflicts\n"
msgstr[0] "attendu %d conflits décalage/réduction"
#: src/conflicts.c:567 src/conflicts.c:688
#: src/conflicts.c:575 src/conflicts.c:696
#, c-format
msgid " %-4s\t[reduce using rule %d (%s)]\n"
msgstr " %-4s\t[réduction par la règle %d (%s)\n"
#: src/conflicts.c:579 src/print.c:156
#: src/conflicts.c:587 src/print.c:156
#, c-format
msgid ""
" $default\treduce using rule %d (%s)\n"
@@ -111,12 +111,12 @@ msgstr ""
" $défaut\tréduction par la règle %d (%s)\n"
"\n"
#: src/conflicts.c:668 src/conflicts.c:682
#: src/conflicts.c:676 src/conflicts.c:690
#, c-format
msgid " %-4s\treduce using rule %d (%s)\n"
msgstr " %-4s\tréduction par la règle %d (%s)\n"
#: src/conflicts.c:708
#: src/conflicts.c:716
#, c-format
msgid " $default\treduce using rule %d (%s)\n"
msgstr " $défaut\tréduction par la règle %d (%s)\n"
@@ -570,70 +570,70 @@ msgstr "la grammaire d
msgid "rule given for %s, which is a token"
msgstr "la règle pour %s, qui est un terminal"
#: src/reader.c:1490
#: src/reader.c:1492
msgid "two @prec's in a row"
msgstr "deux @prec de suite"
#: src/reader.c:1498
#: src/reader.c:1500
#, c-format
msgid "%%guard present but %%semantic_parser not specified"
msgstr "%%guard est présent mais %%semantic_parser n'est pas spécifié"
#: src/reader.c:1507
#: src/reader.c:1509
msgid "two actions at end of one rule"
msgstr "deux actions à la fin d'une même règle"
#: src/reader.c:1521
#: src/reader.c:1523
#, c-format
msgid "type clash (`%s' `%s') on default action"
msgstr "conflit de type (`%s' `%s') pour l'action par défaut"
#: src/reader.c:1527
#: src/reader.c:1529
msgid "empty rule for typed nonterminal, and no action"
msgstr "règle vide pour une catégorie typée et aucune action"
#: src/reader.c:1571
#: src/reader.c:1573
#, c-format
msgid "invalid input: %s"
msgstr "entrée non valide: %s"
#: src/reader.c:1579
#: src/reader.c:1581
#, c-format
msgid "too many symbols (tokens plus nonterminals); maximum %d"
msgstr "trop de symboles (jeton plus non terminaux); maximum %d"
#: src/reader.c:1582
#: src/reader.c:1584
msgid "no rules in the input grammar"
msgstr "la grammaire n'a pas de règles"
#: src/reader.c:1606
#: src/reader.c:1608
#, c-format
msgid "symbol %s is used, but is not defined as a token and has no rules"
msgstr ""
"le symbole %s est utilisé mais ce n'est pas un terminal et il ne possède pas "
"de règle"
#: src/reader.c:1741
#: src/reader.c:1743
#, c-format
msgid "tokens %s and %s both assigned number %d"
msgstr "les jetons %s et %s se sont vus assigner le nombre %d"
#: src/reader.c:1794
#: src/reader.c:1796
#, c-format
msgid "conflicting precedences for %s and %s"
msgstr "les priorités pour %s et %s entrent en conflit"
#: src/reader.c:1806
#: src/reader.c:1808
#, c-format
msgid "conflicting assoc values for %s and %s"
msgstr "les valeurs d'association de %s et %s entrent en conflit"
#: src/reader.c:1845
#: src/reader.c:1847
#, c-format
msgid "the start symbol %s is undefined"
msgstr "le symbole de départ %s n'est pas défini"
#: src/reader.c:1847
#: src/reader.c:1849
#, c-format
msgid "the start symbol %s is a token"
msgstr "le symbole de départ %s est un terminal"