From f67cdd7f258347b3fe21fa3c8bfc335decad02d6 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Wed, 24 Aug 2011 10:46:00 +0300 Subject: [PATCH] Minor changes in bidi.c. src/bidi.c (bidi_check_type): Use xassert. (bidi_cache_iterator_state): Update the disp_pos and disp_prop_p members. --- src/ChangeLog | 6 ++++++ src/bidi.c | 7 ++++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index c629598fcf7..f52e8cad479 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,9 @@ +2011-08-24 Eli Zaretskii + + * bidi.c (bidi_check_type): Use xassert. + (bidi_cache_iterator_state): Update the disp_pos and disp_prop_p + members. + 2011-08-23 Eli Zaretskii * bidi.c (bidi_get_type): Abort if we get zero as the bidi type of diff --git a/src/bidi.c b/src/bidi.c index 00aa31bf48d..425a0be9578 100644 --- a/src/bidi.c +++ b/src/bidi.c @@ -146,11 +146,10 @@ bidi_get_type (int ch, bidi_dir_t override) } } -static void +static inline void bidi_check_type (bidi_type_t type) { - if (type < UNKNOWN_BT || type > NEUTRAL_ON) - abort (); + xassert (UNKNOWN_BT <= type && type <= NEUTRAL_ON); } /* Given a bidi TYPE of a character, return its category. */ @@ -540,6 +539,8 @@ bidi_cache_iterator_state (struct bidi_it *bidi_it, int resolved) bidi_cache[idx].next_for_neutral = bidi_it->next_for_neutral; bidi_cache[idx].next_for_ws = bidi_it->next_for_ws; bidi_cache[idx].ignore_bn_limit = bidi_it->ignore_bn_limit; + bidi_cache[idx].disp_pos = bidi_it->disp_pos; + bidi_cache[idx].disp_prop_p = bidi_it->disp_prop_p; } bidi_cache_last_idx = idx; -- 2.39.5