# HG changeset patch # User stephent # Date 1050422987 0 # Node ID 56496b4938889a6192ad87028e1281508e57b9fe # Parent aa15a2bbba1aeced53a2a43d947df9168bb11408 [xemacs-hg @ 2003-04-15 16:09:46 by stephent] re_match charset bug fix <87of37bv7n.fsf_-_@tleepslib.sk.tsukuba.ac.jp> diff -r aa15a2bbba1a -r 56496b493888 src/ChangeLog --- a/src/ChangeLog Tue Apr 15 15:56:58 2003 +0000 +++ b/src/ChangeLog Tue Apr 15 16:09:47 2003 +0000 @@ -1,3 +1,9 @@ +2003-04-04 Daiki Ueno + + * regex.c (re_match_2_internal): Fix charset/charset_not matching + for extended characters. Fixes KNOWN BUG matching ASCII character + classes to mule characters. + 2003-04-14 Steve Youngs * glyphs.c: @@ -8,10 +14,9 @@ * glyphs.c (glyph_image_instance_maybe): * glyphs.c (glyph_width): Work around a problem compiling with --use-union-type using - Intel's ICC compiler. - From Martin Buchholz + Intel's ICC compiler. From Martin Buchholz See - + 2003-04-08 Mike Sperber diff -r aa15a2bbba1a -r 56496b493888 src/regex.c --- a/src/regex.c Tue Apr 15 15:56:58 2003 +0000 +++ b/src/regex.c Tue Apr 15 16:09:47 2003 +0000 @@ -5341,7 +5341,7 @@ case charset: case charset_not: { - REGISTER unsigned char c; + REGISTER Ichar c; re_bool not_p = (re_opcode_t) *(p - 1) == charset_not; DEBUG_PRINT2 ("EXECUTING charset%s.\n", not_p ? "_not" : ""); @@ -5352,7 +5352,7 @@ /* Cast to `unsigned int' instead of `unsigned char' in case the bit list is a full 32 bytes long. */ - if (c < (unsigned int) (*p * BYTEWIDTH) + if ((unsigned int)c < (unsigned int) (*p * BYTEWIDTH) && p[1 + c / BYTEWIDTH] & (1 << (c % BYTEWIDTH))) not_p = !not_p;