* 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

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: GNU bison 1.28\n"
"POT-Creation-Date: 2001-11-23 15:16+0100\n"
"POT-Creation-Date: 2001-11-26 16:23+0100\n"
"PO-Revision-Date: 1999-09-28 21:10+0900\n"
"Last-Translator: Daisuke Yamashita <yamad@mb.infoweb.ne.jp>\n"
"Language-Team: Japanese <ja@li.org>\n"
@@ -26,7 +26,7 @@ msgstr ""
msgid "warning: "
msgstr ""
#: src/complain.c:238 src/complain.c:279
#: src/complain.c:238
#, fuzzy
msgid "fatal error: "
msgstr "%s: 致命的エラー: "
@@ -72,37 +72,37 @@ msgstr "
#. If invoked with `--yacc', use the output format specified by
#. POSIX.
#: src/conflicts.c:460
#: src/conflicts.c:470
msgid "conflicts: "
msgstr "衝突: "
#: src/conflicts.c:462
#: src/conflicts.c:472
#, c-format
msgid " %d shift/reduce"
msgstr " %d シフト/還元"
#: src/conflicts.c:466
#: src/conflicts.c:476
#, c-format
msgid " %d reduce/reduce"
msgstr " %d 還元/還元"
#: src/conflicts.c:471 src/reduce.c:493
#: src/conflicts.c:481 src/reduce.c:493
#, c-format
msgid "%s contains "
msgstr "%s には"
#: 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] " %d シフト/還元衝突"
#: 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[規則 %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 ""
" $default\t規則 %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\t規則 %d を利用して還元 (%s)\n"
#: src/conflicts.c:708
#: src/conflicts.c:716
#, c-format
msgid " $default\treduce using rule %d (%s)\n"
msgstr " $default\t規則 %d を利用して還元 (%s)\n"
@@ -557,70 +557,70 @@ msgstr "ʸˡ
msgid "rule given for %s, which is a token"
msgstr "%s に規則が与えられ、それはトークンとなります"
#: src/reader.c:1490
#: src/reader.c:1492
msgid "two @prec's in a row"
msgstr "@prec のもの二つが同列になっています"
#: src/reader.c:1498
#: src/reader.c:1500
#, c-format
msgid "%%guard present but %%semantic_parser not specified"
msgstr "%%guard がありますが %%semantic_parser が指定されていません"
#: src/reader.c:1507
#: src/reader.c:1509
msgid "two actions at end of one rule"
msgstr "一つの規則の終りに二つの動作を指定しています"
#: src/reader.c:1521
#: src/reader.c:1523
#, c-format
msgid "type clash (`%s' `%s') on default action"
msgstr "初期状態の動作では型 (`%s' `%s') が衝突します"
#: src/reader.c:1527
#: src/reader.c:1529
msgid "empty rule for typed nonterminal, and no action"
msgstr "空の型付き非終端アイテム用規則であり、動作が起りません"
#: src/reader.c:1571
#: src/reader.c:1573
#, c-format
msgid "invalid input: %s"
msgstr "無効な入力: %s"
#: src/reader.c:1579
#: src/reader.c:1581
#, fuzzy, c-format
msgid "too many symbols (tokens plus nonterminals); maximum %d"
msgstr "シンボルが多すぎます (トークンと非終端アイテム) -- 最大 %s"
#: src/reader.c:1582
#: src/reader.c:1584
msgid "no rules in the input grammar"
msgstr "入力した文法に規則が定義されていません"
#: 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 ""
"シンボル %s が使われていますが、トークンとして定義されておらず、規則を持ちま"
"せん"
#: src/reader.c:1741
#: src/reader.c:1743
#, fuzzy, c-format
msgid "tokens %s and %s both assigned number %d"
msgstr "トークン %s と %s の双方が番号 %s に割り当てられました"
#: src/reader.c:1794
#: src/reader.c:1796
#, c-format
msgid "conflicting precedences for %s and %s"
msgstr "先行している %s と %s で競合が生じています"
#: src/reader.c:1806
#: src/reader.c:1808
#, c-format
msgid "conflicting assoc values for %s and %s"
msgstr "非結合値 %s と %s で競合が生じています"
#: src/reader.c:1845
#: src/reader.c:1847
#, c-format
msgid "the start symbol %s is undefined"
msgstr "開始シンボル %s は定義されていません"
#: src/reader.c:1847
#: src/reader.c:1849
#, c-format
msgid "the start symbol %s is a token"
msgstr "開始シンボル %s はトークンです"