GNU bug report logs -
#4209
23.1; Emacs 23.1 regression in re-search-forward
Previous Next
Full log
View this message in rfc822 format
In article <jwviqanliww.fsf-monnier+emacs <at> gnu.org>, Stefan Monnier <monnier <at> iro.umontreal.ca> writes:
> The preceding comment keeps me puzzled. I thought that we only ever
> matched re_patterns and buffers of the same multibyteness, i.e. if
> a unibyte regexp is matched against a multibyte buffer it should first
> be turned into a multibyte regexp and then re_compiled, so the case of:
Before we changed the behavour of unibyte->multibyte
conversion, that conversion depended on the preferred
charset (thus on lang. env.). But, Emacs 22 wrongly cached
the pattern converted at some point, and reused it without
checking the change of preferred charset.
So, in emacs-unicode branch, I fixed the regex code so that
unibyte pattern can be directry used for multibyte buffer
search by doing unibyte->multibyte conversion on the fly.
And that code was merged to trunk.
So,
> /* For the case of matching this unibyte regex
> against multibyte, we must set a leading code of
> the corresponding multibyte character. */
really happens.
---
Kenichi Handa
handa <at> m17n.org
This bug report was last modified 15 years and 115 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.