From: Paul Eggert Date: Mon, 7 Oct 2002 05:43:35 +0000 (+0000) Subject: (bitset_reset): Do not assume that bitset_word is X-Git-Tag: BISON-1_75~56 X-Git-Url: https://git.saurik.com/bison.git/commitdiff_plain/0f9cd74fdb1f39c38da5abcfca46e2091a55012c (bitset_reset): Do not assume that bitset_word is the same width as int. This reapplies a hunk of the 2002-08-12 patch , which was inadvertently undone by the 2002-09-30 patch. --- diff --git a/lib/bitset.h b/lib/bitset.h index 420ad88e..cfafcaf4 100644 --- a/lib/bitset.h +++ b/lib/bitset.h @@ -167,7 +167,8 @@ do \ bitset_windex _offset = _index - (bset)->b.cindex; \ \ if (_offset < (bset)->b.csize) \ - (bset)->b.cdata[_offset] &= ~(1 << (_bitno % BITSET_WORD_BITS)); \ + (bset)->b.cdata[_offset] &= \ + ~((bitset_word) 1 << (_bitno % BITSET_WORD_BITS)); \ else \ BITSET_RESET_ ((bset), _bitno); \ } while (0)