Subject: Re: bug#38407: 27.0.50; infinite loop with display of large file without newlines

From: Eli Zaretskii <[email-masked]>
Date: Fri, 29 Nov 2019 15:20:24 +0200

> Cc: Pieter van Oostrum <[email-masked]>, [email-masked]
> From: Phil Sainty <[email-masked]>
> Date: Sat, 30 Nov 2019 00:48:22 +1300
> 
> In short, this enhancement seems very effective to me (thank you Eli),
> so I will push the addition to so-long.el shortly.

Thanks.  But note that setting bidi-inhibit-bpa non-nil will help
significantly only for files that are likely to have a lot of bracket
characters, especially if they are nested.  So maybe do that in
so-long.el only for modes where this is likely to happen, if not by
actually counting such characters.  E.g., I wouldn't recommend doing
that in Text mode, since there it might cause incorrect display
without any real benefits.

Characters that I call "bracket" for this purpose are listed in
admin/unidata/BidiBrackets.txt (a file we import from the UCD).
Significantly, the "<>" pair is not there, so files with lots of those
particular brackets will not be affected by this issue.