of the first rule.
* tests/regression.at (Rule Line Numbers, Unresolved SR Conflicts):
(Solved SR Conflicts): Adjust rule 0's line number.
+2001-12-29 Akim Demaille <akim@epita.fr>
+
+ * src/reader.c (readgram): Bind the initial rule's lineno to that
+ of the first rule.
+ * tests/regression.at (Rule Line Numbers, Unresolved SR Conflicts):
+ (Solved SR Conflicts): Adjust rule 0's line number.
+
+
2001-12-29 Akim Demaille <akim@epita.fr>
Fix the `GAWK Grammar' failure.
2001-12-29 Akim Demaille <akim@epita.fr>
Fix the `GAWK Grammar' failure.
- /* Insert the initial rule:
+ /* Insert the initial rule, which line is that of the first rule
+ (not that of the start symbol):
axiom: %start EOF. */
p = symbol_list_new (axiom);
axiom: %start EOF. */
p = symbol_list_new (axiom);
+ p->line = grammar->line;
p->next = symbol_list_new (startval);
p->next->next = symbol_list_new (eoftoken);
p->next->next->next = symbol_list_new (NULL);
p->next = symbol_list_new (startval);
p->next->next = symbol_list_new (eoftoken);
p->next->next->next = symbol_list_new (NULL);
Grammar
Number, Line, Rule
Grammar
Number, Line, Rule
1 3 exp -> exp OP exp
2 3 exp -> NUM
1 3 exp -> exp OP exp
2 3 exp -> NUM
Grammar
Number, Line, Rule
Grammar
Number, Line, Rule
1 4 exp -> exp OP exp
2 4 exp -> NUM
1 4 exp -> exp OP exp
2 4 exp -> NUM
[[Grammar
Number, Line, Rule
[[Grammar
Number, Line, Rule
1 2 @1 -> /* empty */
2 2 expr -> 'a' @1 'b'
3 15 @2 -> /* empty */
1 2 @1 -> /* empty */
2 2 expr -> 'a' @1 'b'
3 15 @2 -> /* empty */