Mercurial > emacs
comparison src/marker.c @ 21219:29d2cf14040a
(byte_char_debug_check): Call multibyte_chars_in_text
instead of chars_in_text because we must ignore
enable-multibyte-characters here.
author | Kenichi Handa <handa@m17n.org> |
---|---|
date | Thu, 19 Mar 1998 07:34:29 +0000 |
parents | 431f875501a6 |
children | 1e2da269ca1f |
comparison
equal
deleted
inserted
replaced
21218:f99248b85ee8 | 21219:29d2cf14040a |
---|---|
103 { | 103 { |
104 int nchars = 0; | 104 int nchars = 0; |
105 | 105 |
106 if (bytepos > BUF_GPT_BYTE (b)) | 106 if (bytepos > BUF_GPT_BYTE (b)) |
107 { | 107 { |
108 nchars = chars_in_text (BUF_BEG_ADDR (b), | 108 nchars = multibyte_chars_in_text (BUF_BEG_ADDR (b), |
109 BUF_GPT_BYTE (b) - BUF_BEG_BYTE (b)); | 109 BUF_GPT_BYTE (b) - BUF_BEG_BYTE (b)); |
110 nchars += chars_in_text (BUF_GAP_END_ADDR (b), | 110 nchars += multibyte_chars_in_text (BUF_GAP_END_ADDR (b), |
111 bytepos - BUF_GPT_BYTE (b)); | 111 bytepos - BUF_GPT_BYTE (b)); |
112 } | 112 } |
113 else | 113 else |
114 nchars = chars_in_text (BUF_BEG_ADDR (b), bytepos - BUF_BEG_BYTE (b)); | 114 nchars = multibyte_chars_in_text (BUF_BEG_ADDR (b), |
115 bytepos - BUF_BEG_BYTE (b)); | |
115 | 116 |
116 if (charpos - 1 != nchars) | 117 if (charpos - 1 != nchars) |
117 abort (); | 118 abort (); |
118 } | 119 } |
119 | 120 |