%printer {} token1 <type1> <type3>
%destructor {} token2 <type2> <type4>
+*** Conflicts
+
+ The warnings and error messages about shift/reduce and reduce/reduce
+ conflicts have been normalized. For instance on the following foo.y file:
+
+ %glr-parser
+ %%
+ exp: exp '+' exp | '0' | '0';
+
+ compare the previous version of bison:
+
+ $ bison foo.y
+ foo.y: conflicts: 1 shift/reduce, 2 reduce/reduce
+ $ bison -Werror foo.y
+ bison: warnings being treated as errors
+ foo.y: conflicts: 1 shift/reduce, 2 reduce/reduce
+
+ with the new behavior:
+
+ $ bison foo.y
+ foo.y: warning: 1 shift/reduce conflict [-Wconflicts-sr]
+ foo.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr]
+ $ bison -Werror foo.y
+ bison: warnings being treated as errors
+ foo.y: warning: 1 shift/reduce conflict [-Wconflicts-sr]
+ foo.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr]
+
+ When %expect or %expect-rr is used, such as with bar.y:
+
+ %expect 0
+ %glr-parser
+ %%
+ exp: exp '+' exp | '0' | '0';
+
+ Former behavior:
+
+ $ bison bar.y
+ bar.y: conflicts: 1 shift/reduce, 2 reduce/reduce
+ bar.y: expected 0 shift/reduce conflicts
+ bar.y: expected 0 reduce/reduce conflicts
+
+ New one:
+
+ $ bison bar.y
+ bar.y: shift/reduce conflicts: 1 found, 0 expected
+ bar.y: reduce/reduce conflicts: 2 found, 0 expected
+
** Additional yylex/yyparse arguments
The new directive %param declares additional arguments to both yylex and
return res;
}
-/*--------------------------------------------------------.
-| Report the number of conflicts, using the Yacc format. |
-`--------------------------------------------------------*/
-
-static void
-conflict_report (FILE *out, size_t src_num, size_t rrc_num)
-{
- if (src_num && rrc_num)
- fprintf (out, _("conflicts: %zd shift/reduce, %zd reduce/reduce\n"),
- src_num, rrc_num);
- else if (src_num)
- fprintf (out, _("conflicts: %zd shift/reduce\n"), src_num);
- else if (rrc_num)
- fprintf (out, _("conflicts: %zd reduce/reduce\n"), rrc_num);
-}
-
/*-----------------------------------------------------------.
| Output the detailed description of states with conflicts. |
state *s = states[i];
if (conflicts[i])
{
+ int src = count_state_sr_conflicts (s);
+ int rrc = count_state_rr_conflicts (s, true);
fprintf (out, _("State %d "), i);
- conflict_report (out,
- count_state_sr_conflicts (s),
- count_state_rr_conflicts (s, true));
+ if (src && rrc)
+ fprintf (out,
+ _("conflicts: %d shift/reduce, %d reduce/reduce\n"),
+ src, rrc);
+ else if (src)
+ fprintf (out, _("conflicts: %d shift/reduce\n"), src);
+ else if (rrc)
+ fprintf (out, _("conflicts: %d reduce/reduce\n"), rrc);
printed_sth = true;
}
}
void
conflicts_print (void)
{
- /* Is the number of SR conflicts OK? Either EXPECTED_CONFLICTS is
- not set, and then we want 0 SR, or else it is specified, in which
- case we want equality. */
- bool src_ok;
- bool rrc_ok;
-
- int src_expected;
- int rrc_expected;
-
- int src_total = count_sr_conflicts ();
- int rrc_total = count_rr_conflicts (true);
-
if (! glr_parser && expected_rr_conflicts != -1)
{
complain (Wother, _("%%expect-rr applies only to GLR parsers"));
expected_rr_conflicts = -1;
}
- src_expected = expected_sr_conflicts == -1 ? 0 : expected_sr_conflicts;
- rrc_expected = expected_rr_conflicts == -1 ? 0 : expected_rr_conflicts;
- src_ok = src_total == src_expected;
- rrc_ok = rrc_total == rrc_expected;
-
- /* If there are as many RR conflicts and SR conflicts as
- expected, then there is nothing to report. */
- if (rrc_ok & src_ok)
- return;
-
- /* Report the total number of conflicts on STDERR. */
- if (expected_sr_conflicts == -1 && expected_rr_conflicts == -1)
- {
- if (!(warnings_flag & Wconflicts_sr))
- src_total = 0;
- if (!(warnings_flag & Wconflicts_rr))
- rrc_total = 0;
- }
- if (src_total | rrc_total)
- {
- if (expected_sr_conflicts == -1 && expected_rr_conflicts == -1)
- set_warning_issued ();
- if (! yacc_flag)
- fprintf (stderr, "%s: ", current_file);
- conflict_report (stderr, src_total, rrc_total);
- }
+ /* Screams for factoring, but almost useless because of the
+ different strings to translate. */
+ {
+ int total = count_sr_conflicts ();
+ // If %expect is not used, but %expect-rr is, then expect 0 sr.
+ int expected =
+ (expected_sr_conflicts == -1 && expected_rr_conflicts != -1)
+ ? 0
+ : expected_sr_conflicts;
+ if (expected != -1)
+ {
+ if (expected != total)
+ complain (complaint,
+ _("shift/reduce conflicts: %d found, %d expected"),
+ total, expected);
+ }
+ else if (total)
+ complain (Wconflicts_sr,
+ ngettext ("%d shift/reduce conflict",
+ "%d shift/reduce conflicts",
+ total),
+ total);
+ }
- if (expected_sr_conflicts != -1 || expected_rr_conflicts != -1)
- {
- if (! src_ok)
- complain (complaint, ngettext ("expected %d shift/reduce conflict",
- "expected %d shift/reduce conflicts",
- src_expected),
- src_expected);
- if (! rrc_ok)
- complain (complaint, ngettext ("expected %d reduce/reduce conflict",
- "expected %d reduce/reduce conflicts",
- rrc_expected),
- rrc_expected);
- }
+ {
+ int total = count_rr_conflicts (true);
+ // If %expect-rr is not used, but %expect is, then expect 0 rr.
+ int expected =
+ (expected_rr_conflicts == -1 && expected_sr_conflicts != -1)
+ ? 0
+ : expected_rr_conflicts;
+ if (expected != -1)
+ {
+ if (expected != total)
+ complain (complaint,
+ _("reduce/reduce conflicts: %d found, %d expected"),
+ total, expected);
+ }
+ else if (total)
+ complain (Wconflicts_rr,
+ ngettext ("%d reduce/reduce conflict",
+ "%d reduce/reduce conflicts",
+ total),
+ total);
+ }
}
# Show canonical LR's failure.
AT_BISON_CHECK([[-Dlr.type=canonical-lr -o input.c input.y]],
[[0]], [[]],
-[[input.y: conflicts: 2 shift/reduce
+[[input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr]
]])
AT_COMPILE([[input]])
AT_PARSER_CHECK([[./input]], [[1]], [[]],
# It's corrected by LAC.
AT_BISON_CHECK([[-Dlr.type=canonical-lr -Dparse.lac=full \
-o input.c input.y]], [[0]], [[]],
-[[input.y: conflicts: 2 shift/reduce
+[[input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr]
]])
AT_COMPILE([[input]])
AT_PARSER_CHECK([[./input]], [[1]], [[]],
# IELR is sufficient when LAC is used.
AT_BISON_CHECK([[-Dlr.type=ielr -Dparse.lac=full -o input.c input.y]],
[[0]], [[]],
-[[input.y: conflicts: 2 shift/reduce
+[[input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr]
]])
AT_COMPILE([[input]])
AT_PARSER_CHECK([[./input]], [[1]], [[]],
]])
AT_BISON_CHECK([-o input.c --report=all input.y], 0, [],
-[input.y: conflicts: 1 shift/reduce
-])
+[[input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr]
+]])
# Check the contents of the report.
AT_CHECK([cat input.output], [],
]])
AT_BISON_CHECK([-o input.c input.y], 0, [],
-[[input.y: conflicts: 1 shift/reduce
+[[input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr]
input.y:12.3-18: warning: rule useless in parser due to conflicts: cond: cond "then" cond [-Wother]
]])
]])
AT_BISON_CHECK([-o input.c --report=all input.y], 0, [],
-[[input.y: conflicts: 1 reduce/reduce
+[[input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
input.y:4.6-8: warning: rule useless in parser due to conflicts: id: '0' [-Wother]
]])
]])
AT_BISON_CHECK([-o input.c input.y], 1, [],
-[input.y: conflicts: 1 shift/reduce
-input.y: expected 0 shift/reduce conflicts
-])
+[[input.y: shift/reduce conflicts: 1 found, 0 expected
+]])
AT_CLEANUP
]])
AT_BISON_CHECK([-o input.c input.y], 1, [],
-[input.y: conflicts: 1 shift/reduce
-input.y: expected 2 shift/reduce conflicts
-])
+[[input.y: shift/reduce conflicts: 1 found, 2 expected
+]])
AT_CLEANUP
]])
AT_BISON_CHECK([-o input.c input.y], 1, [],
-[input.y: conflicts: 1 reduce/reduce
-input.y: expected 0 reduce/reduce conflicts
-])
+[[input.y: reduce/reduce conflicts: 1 found, 0 expected
+]])
AT_CLEANUP
]])
AT_BISON_CHECK([-o input.c input.y], 0, [],
-[[input.y: conflicts: 4 shift/reduce
+[[input.y: warning: 4 shift/reduce conflicts [-Wconflicts-sr]
]])
AT_CLEANUP
]])
AT_BISON_CHECK([[--report=all input.y]], 0, [],
-[[input.y: conflicts: 1 shift/reduce, 1 reduce/reduce
+[[input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr]
+input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
input.y:12.5-20: warning: rule useless in parser due to conflicts: resolved_conflict: 'a' unreachable1 [-Wother]
input.y:20.5-20: warning: rule useless in parser due to conflicts: unreachable1: 'a' unreachable2 [-Wother]
input.y:21.4: warning: rule useless in parser due to conflicts: unreachable1: /* empty */ [-Wother]
AT_CHECK([[cat input.y >> input-keep.y]])
AT_BISON_CHECK([[input-keep.y]], 0, [],
-[[input-keep.y: conflicts: 2 shift/reduce, 2 reduce/reduce
+[[input-keep.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr]
+input-keep.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr]
input-keep.y:22.4: warning: rule useless in parser due to conflicts: unreachable1: /* empty */ [-Wother]
input-keep.y:26.16: warning: rule useless in parser due to conflicts: unreachable2: /* empty */ [-Wother]
input-keep.y:32.5-7: warning: rule useless in parser due to conflicts: reported_conflicts: 'a' [-Wother]
AT_BISON_CHECK([[2.y]], [[0]], [],
[[2.y: warning: %expect-rr applies only to GLR parsers [-Wother]
-2.y: conflicts: 1 reduce/reduce
+2.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
2.y:3.12-14: warning: rule useless in parser due to conflicts: exp: 'a' [-Wother]
]])
]])
AT_BISON_CHECK([[sr-rr.y]], [[0]], [[]],
-[[sr-rr.y: conflicts: 1 shift/reduce, 1 reduce/reduce
+[[sr-rr.y: warning: 1 shift/reduce conflict [-Wconflicts-sr]
+sr-rr.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
]])
AT_BISON_CHECK([[-Wno-conflicts-sr sr-rr.y]], [[0]], [[]],
-[[sr-rr.y: conflicts: 1 reduce/reduce
+[[sr-rr.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
]])
AT_BISON_CHECK([[-Wno-conflicts-rr sr-rr.y]], [[0]], [[]],
-[[sr-rr.y: conflicts: 1 shift/reduce
+[[sr-rr.y: warning: 1 shift/reduce conflict [-Wconflicts-sr]
]])
-[for gram in sr-rr sr rr; do
+[
+# This is piece of code is rather complex for a simple task: try every
+# combinaison of (0 or 1 real SR) x (0 or 1 real RR) x (don't %expect
+# or %expect 0, 1, or 2 SR) x (don't %expect-rr or %expect-rr 0, 1, or 2
+# RR).
+
+# Number and types of genuine conflicts in the grammar.
+for gram in sr-rr sr rr; do
+ # Number of expected s/r conflicts.
for sr_exp_i in '' 0 1 2; do
+ # Number of expected r/r conflicts.
for rr_exp_i in '' 0 1 2; do
test -z "$sr_exp_i" && test -z "$rr_exp_i" && continue
echo "$directives" > $file
cat $gram.y >> $file
- # Count actual conflicts.
- conflicts=
- sr_count=0
- rr_count=0
- if test $gram = sr || test $gram = sr-rr; then
- conflicts="1 shift/reduce"
- sr_count=1
- fi
- if test $gram = rr || test $gram = sr-rr; then
- if test -n "$conflicts"; then
- conflicts="$conflicts, "
- fi
- conflicts="${conflicts}1 reduce/reduce"
- rr_count=1
- fi
+ # Number of found conflicts.
+ case $gram in
+ (sr) sr_count=1; rr_count=0;;
+ (rr) sr_count=0; rr_count=1;;
+ (sr-rr) sr_count=1; rr_count=1;;
+ esac
+
+ # Update number of expected conflicts: if %expect is given then
+ # %expect-rr defaults to 0, and vice-versa. Leave empty if
+ # nothing expected.
+ case $sr_exp_i:$rr_exp_i in
+ ?:) rr_exp_i=0;;
+ :?) sr_exp_i=0;;
+ esac
# Run tests.
if test $sr_count -eq $sr_exp && test $rr_count -eq $rr_exp; then
]AT_BISON_CHECK([[-Wnone $file]])[
]AT_BISON_CHECK([[-Werror $file]])[
else
- echo "$file: conflicts: $conflicts" > experr
- if test $sr_count -ne $sr_exp; then
- if test $sr_exp -ne 1; then s=s; else s= ; fi
- echo "$file: expected $sr_exp shift/reduce conflict$s" >> experr
- fi
- if test $rr_count -ne $rr_exp; then
- if test $rr_exp -ne 1; then s=s; else s= ; fi
- echo "$file: expected $rr_exp reduce/reduce conflict$s" >> experr
- fi
+ {
+ if test -z "$sr_exp_i" && test "$sr_count" -ne 0; then
+ echo "warning: $sr_count shift/reduce conflicts"
+ elif test "$sr_exp_i" -ne "$sr_count"; then
+ echo "shift/reduce conflicts: $sr_count found, $sr_exp_i expected"
+ fi
+ if test -z "$rr_exp_i" && test "$rr_count" -ne 0; then
+ echo "warning: $rr_count reduce/reduce conflicts"
+ elif test "$rr_exp_i" -ne "$rr_count"; then
+ echo "reduce/reduce conflicts: $rr_count found, $rr_exp_i expected"
+ fi
+ } | sed -e "s/^/$file: /" > experr
]AT_BISON_CHECK([[-Wnone $file]], [[1]], [[]], [[experr]])[
]AT_BISON_CHECK([[-Werror $file]], [[1]], [[]], [[experr]])[
fi
dnl BISON-STDERR
[AT_COND_CASE([[canonical LR]],
-[[input.y: conflicts: 265 shift/reduce]],
-[[input.y: conflicts: 65 shift/reduce]])[
+[[input.y: warning: 265 shift/reduce conflicts [-Wconflicts-sr]]],
+[[input.y: warning: 65 shift/reduce conflicts [-Wconflicts-sr]]])[
]],
dnl LAST-STATE
dnl BISON-STDERR
[AT_COND_CASE([[canonical LR]],
-[[input.y: conflicts: 1876 shift/reduce, 144 reduce/reduce]],
-[[input.y: conflicts: 78 shift/reduce, 10 reduce/reduce]])[
+[[input.y: warning: 1876 shift/reduce conflicts [-Wconflicts-sr]
+input.y: warning: 144 reduce/reduce conflicts [-Wconflicts-rr]]],
+[[input.y: warning: 78 shift/reduce conflicts [-Wconflicts-sr]
+input.y: warning: 10 reduce/reduce conflicts [-Wconflicts-rr]]])[
]],
dnl LAST-STATE
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr1.c glr-regr1.y]], 0, [],
-[glr-regr1.y: conflicts: 1 shift/reduce
-])
+[[glr-regr1.y: warning: 1 shift/reduce conflict [-Wconflicts-sr]
+]])
AT_COMPILE([glr-regr1])
AT_PARSER_CHECK([[echo BPBPB | ./glr-regr1]], 0,
[[E -> 'B'
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr2a.c glr-regr2a.y]], 0, [],
-[glr-regr2a.y: conflicts: 2 shift/reduce
-])
+[[glr-regr2a.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr]
+]])
AT_COMPILE([glr-regr2a])
AT_PARSER_CHECK([[echo s VARIABLE_1 t v x q | ./glr-regr2a]], 0,
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr3.c glr-regr3.y]], 0, [],
-[glr-regr3.y: conflicts: 1 shift/reduce, 1 reduce/reduce
-])
+[[glr-regr3.y: warning: 1 shift/reduce conflict [-Wconflicts-sr]
+glr-regr3.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
+]])
AT_COMPILE([glr-regr3])
AT_PARSER_CHECK([[echo p1 t4 o2 p1 p1 t1 o1 t2 p2 o1 t3 p2 p2 | ./glr-regr3]],
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr4.c glr-regr4.y]], 0, [],
-[glr-regr4.y: conflicts: 1 reduce/reduce
-])
+[[glr-regr4.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
+]])
AT_COMPILE([glr-regr4])
AT_PARSER_CHECK([[./glr-regr4]], 0,
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr5.c glr-regr5.y]], 0, [],
-[glr-regr5.y: conflicts: 1 reduce/reduce
-])
+[[glr-regr5.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
+]])
AT_COMPILE([glr-regr5])
AT_PARSER_CHECK([[./glr-regr5]], 0, [],
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr6.c glr-regr6.y]], 0, [],
-[glr-regr6.y: conflicts: 1 reduce/reduce
-])
+[[glr-regr6.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
+]])
AT_COMPILE([glr-regr6])
AT_PARSER_CHECK([[./glr-regr6]], 0,
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr7.c glr-regr7.y]], 0, [],
-[glr-regr7.y: conflicts: 2 reduce/reduce
-])
+[[glr-regr7.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr]
+]])
AT_COMPILE([glr-regr7])
AT_PARSER_CHECK([[./glr-regr7]], 2, [],
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr8.c glr-regr8.y]], 0, [],
-[glr-regr8.y: conflicts: 1 reduce/reduce
-])
+[[glr-regr8.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
+]])
AT_COMPILE([glr-regr8])
AT_PARSER_CHECK([[./glr-regr8]], 0,
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr9.c glr-regr9.y]], 0, [],
-[glr-regr9.y: conflicts: 1 reduce/reduce
-])
+[[glr-regr9.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
+]])
AT_COMPILE([glr-regr9])
AT_PARSER_CHECK([[./glr-regr9]], 0, [],
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr10.c glr-regr10.y]], 0, [],
-[glr-regr10.y: conflicts: 1 reduce/reduce
-])
+[[glr-regr10.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
+]])
AT_COMPILE([glr-regr10])
AT_PARSER_CHECK([[./glr-regr10]], 0, [], [])
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr11.c glr-regr11.y]], 0, [],
-[glr-regr11.y: conflicts: 1 reduce/reduce
-])
+[[glr-regr11.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
+]])
AT_COMPILE([glr-regr11])
AT_PARSER_CHECK([[./glr-regr11]], 0, [], [])
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr12.c glr-regr12.y]], 0, [],
-[glr-regr12.y: conflicts: 1 shift/reduce, 1 reduce/reduce
-])
+[[glr-regr12.y: warning: 1 shift/reduce conflict [-Wconflicts-sr]
+glr-regr12.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
+]])
AT_COMPILE([glr-regr12])
AT_PARSER_CHECK([[./glr-regr12]], 0, [], [])
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr14.c glr-regr14.y]], 0, [],
-[glr-regr14.y: conflicts: 3 reduce/reduce
-])
+[[glr-regr14.y: warning: 3 reduce/reduce conflicts [-Wconflicts-rr]
+]])
AT_COMPILE([glr-regr14])
AT_PARSER_CHECK([[./glr-regr14]], 0,
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr15.c glr-regr15.y]], 0, [],
-[glr-regr15.y: conflicts: 2 reduce/reduce
-])
+[[glr-regr15.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr]
+]])
AT_COMPILE([glr-regr15])
AT_PARSER_CHECK([[./glr-regr15]], 0, [],
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr16.c glr-regr16.y]], 0, [],
-[glr-regr16.y: conflicts: 1 reduce/reduce
-])
+[[glr-regr16.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
+]])
AT_COMPILE([glr-regr16])
AT_PARSER_CHECK([[./glr-regr16]], 0, [],
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o glr-regr17.c glr-regr17.y]], 0, [],
-[glr-regr17.y: conflicts: 3 reduce/reduce
-])
+[[glr-regr17.y: warning: 3 reduce/reduce conflicts [-Wconflicts-rr]
+]])
AT_COMPILE([glr-regr17])
AT_PARSER_CHECK([[./glr-regr17]], 0, [],
AT_BISON_OPTION_POPDEFS
AT_BISON_CHECK([[-o input.c input.y]], 0, [],
-[input.y: conflicts: 1 reduce/reduce
-])
+[[input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
+]])
AT_COMPILE([input])
AT_PARSER_CHECK([[./input]], 1, [],
dnl BISON-STDERR
[AT_COND_CASE([[LALR]],
-[[input.y: conflicts: 1 reduce/reduce
+[[input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr]
]], [])],
dnl TABLES
AT_BISON_CHECK([[-Dparse.lac=full -Dparse.lac.es-capacity-initial=1 \
-Dparse.lac.memory-trace=full \
-t -o input.c input.y]], [[0]], [],
-[[input.y: conflicts: 21 shift/reduce
+[[input.y: warning: 21 shift/reduce conflicts [-Wconflicts-sr]
]])
AT_COMPILE([[input]])
AT_PARSER_CHECK([[./input > stdout.txt 2> stderr.txt]], [[1]])
AT_BISON_CHECK([[-Dparse.lac=full -Dparse.lac.es-capacity-initial=1 \
-t -o input.c input.y]], [[0]], [],
-[[input.y: conflicts: 8 shift/reduce
+[[input.y: warning: 8 shift/reduce conflicts [-Wconflicts-sr]
]])
AT_COMPILE([[input]])
AT_BISON_OPTION_POPDEFS