mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-16 10:50:49 -08:00
Fix handling of brackets in BPA
* src/bidi.c (bidi_resolve_brackets): Fix implementation of UBA's N0 rule when there are no strong directional characters inside the bracketed pair. (Bug#54219)
This commit is contained in:
parent
225e0d6047
commit
cd51d9c7ab
1 changed files with 3 additions and 1 deletions
|
|
@ -2924,7 +2924,8 @@ bidi_resolve_brackets (struct bidi_it *bidi_it)
|
||||||
eassert (bidi_it->bracket_pairing_pos > bidi_it->charpos);
|
eassert (bidi_it->bracket_pairing_pos > bidi_it->charpos);
|
||||||
if (bidi_it->bracket_enclosed_type == embedding_type) /* N0b */
|
if (bidi_it->bracket_enclosed_type == embedding_type) /* N0b */
|
||||||
type = embedding_type;
|
type = embedding_type;
|
||||||
else
|
else if (bidi_it->bracket_enclosed_type == STRONG_L /* N0c, N0d */
|
||||||
|
|| bidi_it->bracket_enclosed_type == STRONG_R)
|
||||||
{
|
{
|
||||||
switch (bidi_it->prev_for_neutral.type)
|
switch (bidi_it->prev_for_neutral.type)
|
||||||
{
|
{
|
||||||
|
|
@ -2944,6 +2945,7 @@ bidi_resolve_brackets (struct bidi_it *bidi_it)
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
/* N0d: Do not set the type for that bracket pair. */
|
/* N0d: Do not set the type for that bracket pair. */
|
||||||
|
/* (Actuallly, this shouldn't happen.) */
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue