-
- case charset_not:
- /* Chars beyond end of bitmap are possible matches.
- All the single-byte codes can occur in multibyte buffers.
- So any that are not listed in the charset
- are possible matches, even in multibyte buffers. */
- simple_char_max = (1 << BYTEWIDTH);
- for (j = CHARSET_BITMAP_SIZE (&p[-1]) * BYTEWIDTH;
- j < simple_char_max; j++)
- fastmap[j] = 1;
-
- for (j = CHARSET_BITMAP_SIZE (&p[-1]) * BYTEWIDTH - 1, p++;
- j >= 0; j--)
- if (!(p[j / BYTEWIDTH] & (1 << (j % BYTEWIDTH))))
- fastmap[j] = 1;
-
- if (bufp->multibyte)
- /* Any character set can possibly contain a character
- which doesn't match the specified set of characters. */
- {
- set_fastmap_for_multibyte_characters:
- if (match_any_multibyte_characters == false)
- {
- for (j = 0x80; j < 0xA0; j++) /* XXX */
- if (BASE_LEADING_CODE_P (j))
- fastmap[j] = 1;
- match_any_multibyte_characters = true;
- }
- }
- break;
-
-
- case wordchar:
- /* All the single-byte codes can occur in multibyte buffers,
- and they may have word syntax. So do consider them. */
- simple_char_max = (1 << BYTEWIDTH);
- for (j = 0; j < simple_char_max; j++)
- if (SYNTAX (j) == Sword)
- fastmap[j] = 1;
-
- if (bufp->multibyte)
- /* Any character set can possibly contain a character
- whose syntax is `Sword'. */
- goto set_fastmap_for_multibyte_characters;
- break;
-
-
- case notwordchar:
- /* All the single-byte codes can occur in multibyte buffers,
- and they may not have word syntax. So do consider them. */
- simple_char_max = (1 << BYTEWIDTH);
- for (j = 0; j < simple_char_max; j++)
- if (SYNTAX (j) != Sword)
- fastmap[j] = 1;
-
- if (bufp->multibyte)
- /* Any character set can possibly contain a character
- whose syntax is not `Sword'. */
- goto set_fastmap_for_multibyte_characters;
- break;
-#endif
-
- case anychar:
- {
- int fastmap_newline = fastmap['\n'];
-
- /* `.' matches anything, except perhaps newline.
- Even in a multibyte buffer, it should match any
- conceivable byte value for the fastmap. */
- if (bufp->multibyte)
- match_any_multibyte_characters = true;
-
- simple_char_max = (1 << BYTEWIDTH);
- for (j = 0; j < simple_char_max; j++)
- fastmap[j] = 1;
-
- /* ... except perhaps newline. */
- if (!(bufp->syntax & RE_DOT_NEWLINE))
- fastmap['\n'] = fastmap_newline;
-
- /* Otherwise, have to check alternative paths. */
- break;
- }
-
-#ifdef emacs
- case wordbound:
- case notwordbound:
- case wordbeg:
- case wordend:
- case notsyntaxspec: