Mercurial > emacs
comparison src/search.c @ 45263:eeec3bb72a1b
(search_buffer): Give up boyer moore search if inverse
translation change charset_base.
author | Kenichi Handa <handa@m17n.org> |
---|---|
date | Mon, 13 May 2002 00:06:01 +0000 |
parents | 4383b69f181b |
children | 40db0673e6f0 |
comparison
equal
deleted
inserted
replaced
45262:780424a19a2b | 45263:eeec3bb72a1b |
---|---|
1227 if (translated != c || inverse != c) | 1227 if (translated != c || inverse != c) |
1228 { | 1228 { |
1229 /* Keep track of which character set row | 1229 /* Keep track of which character set row |
1230 contains the characters that need translation. */ | 1230 contains the characters that need translation. */ |
1231 int charset_base_code = c & ~CHAR_FIELD3_MASK; | 1231 int charset_base_code = c & ~CHAR_FIELD3_MASK; |
1232 if (charset_base == -1) | 1232 int inverse_charset_base = inverse & ~CHAR_FIELD3_MASK; |
1233 | |
1234 if (charset_base_code != inverse_charset_base) | |
1235 boyer_moore_ok = 0; | |
1236 else if (charset_base == -1) | |
1233 charset_base = charset_base_code; | 1237 charset_base = charset_base_code; |
1234 else if (charset_base != charset_base_code) | 1238 else if (charset_base != charset_base_code) |
1235 /* If two different rows appear, needing translation, | 1239 /* If two different rows appear, needing translation, |
1236 then we cannot use boyer_moore search. */ | 1240 then we cannot use boyer_moore search. */ |
1237 boyer_moore_ok = 0; | 1241 boyer_moore_ok = 0; |