mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-14 23:03:04 +00:00
Use b4_subtract where possible.
* data/lalr1.cc (b4_subtract): Move to... * data/bison.m4: here. * data/glr.c (b4_rhs_data): Use it. * data/yacc.c (b4_rhs_value, b4_rhs_location): Use it.
This commit is contained in:
@@ -117,7 +117,7 @@ m4_define([b4_lhs_value],
|
||||
# Expand to the semantic stack place that contains value and location
|
||||
# of symbol number NUM in a rule of length RULE-LENGTH.
|
||||
m4_define([b4_rhs_data],
|
||||
[((yyGLRStackItem const *)yyvsp)@{YYFILL (($2) - ($1))@}.yystate])
|
||||
[((yyGLRStackItem const *)yyvsp)@{YYFILL (b4_subtract([$2], [$1]))@}.yystate])
|
||||
|
||||
|
||||
# b4_rhs_value(RULE-LENGTH, NUM, [TYPE])
|
||||
|
||||
Reference in New Issue
Block a user