[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: master 79d9f3982f: Add derived-mode test for bug#24176
From: |
Stefan Monnier |
Subject: |
Re: master 79d9f3982f: Add derived-mode test for bug#24176 |
Date: |
Tue, 25 Jan 2022 08:10:56 -0500 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) |
>>> And font-lock-keywords should then be...
>>> (t (("c" 0 'font-lock-keyword-face)))?
>> I think so, yes, or maybe b+c, but it definitely should not be a+b.
> Hm... do you see any obvious way to fix this? We could document that
> you have to set font-lock-set-defaults to nil if you're setting
> font-lock-defaults in a derived mode, but that's not very
> satisfactory... or we could store the value of font-lock-defaults and
> check whether it's changed (in font-lock-set-defaults)? Hm...
I'm not completely sure either, no.
I do think we should strive to make `font-lock-add/remove-keywords` work
in a more "declarative" way, such that we can throw away
`font-lock-keywords` and recompute it at any time.
Stefan