1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-02-18 06:01:22 -08:00

(INC_TEXT_POS, DEC_TEXT_POS): Add parameter MULTIBYTE_P.

This commit is contained in:
Gerd Moellmann 2000-03-27 16:02:34 +00:00
parent 7439e5b9ca
commit 7bed37e412

View file

@ -130,21 +130,27 @@ struct text_pos
/* Increment text position POS. */
#define INC_TEXT_POS(POS) \
#define INC_TEXT_POS(POS, MULTIBYTE_P) \
do \
{ \
++(POS).charpos; \
INC_POS ((POS).bytepos); \
if (MULTIBYTE_P) \
INC_POS ((POS).bytepos); \
else \
++(POS).bytepos; \
} \
while (0)
/* Decrement text position POS. */
#define DEC_TEXT_POS(POS) \
#define DEC_TEXT_POS(POS, MULTIBYTE_P) \
do \
{ \
--(POS).charpos; \
DEC_POS ((POS).bytepos); \
if (MULTIBYTE_P) \
DEC_POS ((POS).bytepos); \
else \
--(POS).bytepos; \
} \
while (0)