[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Emacsy: Context Sensitive Commands Design Question
From: |
Mark H Weaver |
Subject: |
Re: Emacsy: Context Sensitive Commands Design Question |
Date: |
Thu, 29 Aug 2013 22:02:55 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) |
Shane Celis <address@hidden> writes:
> 6. Tag commands as special procedures perhaps by adding something to
> their procedure properties. Implement a "command?" procedure. Export
> commands and procedures to the same module. Then just pluck the
> commands out of all the procedures by using command?.
This is closest to what Emacs does, and probably the best solution, IMO. See
<https://www.gnu.org/software/emacs/manual/html_node/elisp/Interactive-Call.html>
which describes the 'commandp' predicate, whose definition is in eval.c.
Regards,
Mark