emacs-devel
[Top][All Lists]
Advanced

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

Re: [SUSPECTED SPAM] Re: [Emacs-diffs] scratch/widen-less a4ba846: Repla


From: Stefan Monnier
Subject: Re: [SUSPECTED SPAM] Re: [Emacs-diffs] scratch/widen-less a4ba846: Replace prog-widen with consolidating widen calls
Date: Thu, 14 Dec 2017 09:01:42 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

> It keeps prog-indentation-context for its first element (for
> change-minimization and possibly emotional reasons; but who knows, someday
> we might add some, specific only to indentation). The added bonus is that
> calling prog-first-column is easier than digging out the first element of
> the list.

Looks good.

> - Manual changes describing that font-lock matchers shouldn't call 'widen'
> either.  It's an important thing, but so far it's been only an issue with CC
> Mode, which isn't supported anyway (so far). So: should that info be
> included, and where should I put it?

font-lock has always widened (except when font-lock-dont-widen is set,
which AFAICT is only the case in rmail.el), so that's probably why no
major mode widens (CC mode probably widens during font-lock because it
uses functions which are also used in other circumstances where they
need to widen).

So I don't think we need to make any changes on that front.

> - Similar info for syntax-propertize-function, though no violators have been
> observed so far.

Since there are no current violators, we can fix this part of the doc
when we fix the corresponding code.

> What is not included, and maybe should wait until Emacs 27:
> - Similar consolidations of 'widen' calls for add-log-current-defun,
> eldoc-print-current-symbol-info, beginning-of-defun-function and others. And
> accompanying documentation (again, where should it go?).

Maybe some of the doc should be in the narrowing section, where we can
document the contexts where the narrowing is "guaranteed"
(e.g. font-lock and indentation).


        Stefan



reply via email to

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