[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: master 8f28a1b: Tweak `condition-case' keyword highlights
From: |
Stefan Monnier |
Subject: |
Re: master 8f28a1b: Tweak `condition-case' keyword highlights |
Date: |
Sun, 24 Jan 2021 18:10:47 -0500 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
> But speaking of other code that's mis-highlighted still:
>
> (defun a (when b c)
> ...)
>
> (The `when' isn't a keyword here, but it's font-locked as such.)
Yes, that one annoys me fairly often (typically with an arg named `function`).
> Couldn't we just use `edebug-form-spec' to notice that the arglist isn't
> a funcall position?
In theory, yes. That could cover `condition-case` as well ;-)
I think it'd be nice to use this spec for other things than just
debugging [ I remember a discussion a few .. months? .. back where
another possible use came up... oh yes, it was in the discussion about
preserving source-code location, where we could make use of this info
in order to know when the sexp is "code" which can then come with extra
annotations vs "data" in which case we need the unannotated sexp. ]
Stefan