emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: emacs master + org Wrong type argument: number-or-marker-p


From: Eli Zaretskii
Subject: Re: emacs master + org Wrong type argument: number-or-marker-p
Date: Wed, 03 Aug 2022 15:02:12 +0300

> From: Po Lu <luangruo@yahoo.com>
> Cc: acm@muc.de,  gregory@heytings.org,  mattiase@acm.org,
>   philipk@posteo.net,  silent2600@gmail.com,  emacs-devel@gnu.org
> Date: Wed, 03 Aug 2022 12:34:07 +0800
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> > It isn't a hypothetical problem.  You can try the examples posted here
> > yourself, after disabling the feature.  Try it once with and then
> > without font-lock, and draw your own conclusions.
> 
> Then wouldn't it be better to fix the font-locking code to not widen
> outside bounds explictly specified by redisplay, instead of making
> `widen' and `narrow-to-region' in effect inoperable in those
> circumstances?

How would that work in practice?  Font-locking code uses functions and
regexps provided by the major modes, so it cannot by itself prevent
widening.  Many major modes want their fontification to start from the
beginning of the line, which can be very far in a buffer with long
lines; and quite a few major modes use code that widens to BOB.

What can font-lock do to prevent that?




reply via email to

[Prev in Thread] Current Thread [Next in Thread]