[Top][All Lists]

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

Re: master 8f28a1b: Tweak `condition-case' keyword highlights

From: Lars Ingebrigtsen
Subject: Re: master 8f28a1b: Tweak `condition-case' keyword highlights
Date: Tue, 26 Jan 2021 01:25:45 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Stefan Monnier <monnier@iro.umontreal.ca> writes:

>> (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`).

Yeah, me too.

>> 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 ;-)

Indeed.  I'm not sure how high our ambitions here are, though -- getting
this right for all forms may be too slow.  I was thinking we'd get 95%
of the way here by just looking at the "simple" form specs.  Let's
see...  what's the spec for `condition-case'...

(symbolp form &rest
         ([&or symbolp
               (&rest symbolp)]

Well, OK, perhaps that's not unrealistic to apply in an efficient manner.

> 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.  ]


(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no

reply via email to

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