}
}
- /* Some tokens have been explicitly made errors. Allocate a
- permanent errs structure for this state, to record them. */
- state_errs_set (s, nerrs, errors);
+ if (nerrs)
+ {
+ /* Some tokens have been explicitly made errors. Allocate a
+ permanent errs structure for this state, to record them. */
+ state_errs_set (s, nerrs, errors);
+ }
if (obstack_object_size (&solved_conflicts_obstack))
{
for (i = 0; i < reds->num; ++i)
if (reds->rules[i]->prec && reds->rules[i]->prec->prec
&& !bitset_disjoint_p (reds->lookaheads[i], lookaheadset))
- {
- resolve_sr_conflict (s, i, errors);
- break;
- }
+ resolve_sr_conflict (s, i, errors);
/* Loop over all rules which require lookahead in this state. Check
for conflicts not resolved above. */
+`----------------------------------------------------------------*/
static int
-count_rr_conflicts (state *s, int one_per_token)
+count_rr_conflicts (state *s, bool one_per_token)
{
int i;
reductions *reds = s->reductions;
/* 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. */
- int src_ok = 0;
+ bool src_ok = false;
int src_total = 0;
int rrc_total = 0;