From cb581495e689b4875c96eea8135f09d8a72eaacc Mon Sep 17 00:00:00 2001 From: Akim Demaille Date: Thu, 13 Dec 2001 11:02:04 +0000 Subject: [PATCH] * src/closure.c (closure): Use nrules instead of playing tricks with BITS_PER_WORD. --- ChangeLog | 5 +++++ src/closure.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 2e936b0a..b411c7e0 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2001-12-13 Akim Demaille + + * src/closure.c (closure): Use nrules instead of playing tricks + with BITS_PER_WORD. + 2001-12-13 Akim Demaille * src/print.c (print_actions): Output the handling of `$' as the diff --git a/src/closure.c b/src/closure.c index 77ca72c8..12bb5817 100644 --- a/src/closure.c +++ b/src/closure.c @@ -220,7 +220,7 @@ closure (short *core, int n) nitemset = 0; c = 0; - for (ruleno = 0; ruleno < rulesetsize * BITS_PER_WORD; ++ruleno) + for (ruleno = 0; ruleno < nrules + 1; ++ruleno) if (BITISSET (ruleset, ruleno)) { int itemno = rule_table[ruleno].rhs; -- 2.47.2