[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: improve regex bitset performance (don't assume 32 bits)
From: |
Paul Eggert |
Subject: |
Re: improve regex bitset performance (don't assume 32 bits) |
Date: |
Tue, 06 Sep 2005 10:51:45 -0700 |
User-agent: |
Gnus/5.1007 (Gnus v5.10.7) Emacs/21.4 (gnu/linux) |
Derek Price <address@hidden> writes:
> regex_internal.h:837: warning: suggest parentheses around + or - in operand
> of &
Thanks for reporting that. I installed this patch and updated the glibc
bug report.
2005-09-06 Paul Eggert <address@hidden>
* lib/regex_internal.h (bitset_not):
Add parens to avoid gcc -Wall warning.
--- lib/regex_internal.h 6 Sep 2005 07:36:48 -0000 1.13
+++ lib/regex_internal.h 6 Sep 2005 17:50:47 -0000 1.14
@@ -833,7 +833,7 @@ bitset_not (bitset set)
set[i] = ~set[i];
if (SBC_MAX % BITSET_WORD_BITS != 0)
set[BITSET_WORDS - 1] =
- (((bitset_word) 1 << SBC_MAX % BITSET_WORD_BITS) - 1
+ ((((bitset_word) 1 << SBC_MAX % BITSET_WORD_BITS) - 1)
& ~set[BITSET_WORDS - 1]);
}