emacs-devel
[Top][All Lists]
Advanced

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

Re: Current mode command discovery


From: Dmitry Gutov
Subject: Re: Current mode command discovery
Date: Thu, 18 Feb 2021 00:46:01 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0

On 17.02.2021 19:52, Lars Ingebrigtsen wrote:
Dmitry Gutov <dgutov@yandex.ru> writes:

Moving the checking logic inside the read-extended-command-predicate
implementation seems logical.

I'm not sure I understand what you mean here...  that's where the
checking is done today?

Bad phrasing, I guess.

I'm referring to the same thing you do below: that byte-run--set-modes just sets the 'completion-predicate' property, instead of setting some transparent tag which any read-extended-command-predicate could interpret according to its own particular intent.

(declare (modes ...)) would just add a tag to the command, with
natural possibility to add other tags, which a different
read-extended-command-predicate could use.

Yeah, I think so too -- (declare (modes ...)) should have the same
effect as `interactive "p" ...', not create a predicate.  Probably.

Or both (interactive "p" ...) and (declare (modes ...)) should do something similar to what (declare (completion ...)) does (except use a different property).

I'm curious to know whether the change in performance will be at all noticeable.



reply via email to

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