From: "Stefan Monnier" <monnier+gnu/emacs@RUM.cs.yale.edu>
Cc: "Stefan Monnier" <monnier+gnu/emacs@rum.cs.yale.edu>,
rms@gnu.org, emacs-devel@gnu.org
Subject: Re: Command remapping and the delete-frame problem.
Date: Fri, 22 Feb 2002 14:38:37 -0500 [thread overview]
Message-ID: <200202221938.g1MJcbn31112@rum.cs.yale.edu> (raw)
In-Reply-To: 5x3cztjotz.fsf@kfs2.cua.dk
> "Stefan Monnier" <monnier+gnu/emacs@rum.cs.yale.edu> writes:
>
> > > But the interface to define-key, lookup-key and key-binding hasn't
> > > changed. They just take FOO as the KEY argument - which is still an
> > > unambuguous way to represent command remapping, as those functions
> > > don't otherwise accept a symbol as the KEY argument.
> >
> > That now sounds like a hack and I don't think it's worth keeping it.
> > Especially since it's not compatible with the XEmacs hack where
> > a non-vector argument passed to one of those functions is interpreted
> > the same as a length-1 vector so you can
> >
> > (define-key 'button1 'command)
>
> The main reason for allowing the symbol name in the first place was
> that it is marginally more efficient in command_loop_1 to call
> Fkey_binding and thus Flookup_key with a symbol name (the command
> found by read_key_sequence), rather than building a 2-element vector
> [command CMD] and using that to call Fkey_binding.
As RMS suggested, we can pre-build a 2-element vector and always use
that same one, so the loop still doesn't need to allocate.
Stefan
_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://mail.gnu.org/mailman/listinfo/emacs-devel
next prev parent reply other threads:[~2002-02-22 19:38 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <5x3czwjqxs.fsf@kfs2.cua.dk>
[not found] ` <7263-Wed20Feb2002194728+0200-eliz@is.elta.co.il>
[not found] ` <5xd6yzwxs8.fsf@kfs2.cua.dk>
[not found] ` <200202220433.g1M4XP414080@aztec.santafe.edu>
[not found] ` <5xd6yx965v.fsf_-_@kfs2.cua.dk>
2002-02-22 15:40 ` Command remapping and the delete-frame problem Kim F. Storm
2002-02-22 16:24 ` Stefan Monnier
2002-02-22 19:31 ` Kim F. Storm
2002-02-22 19:38 ` Stefan Monnier [this message]
2002-02-23 20:19 ` Richard Stallman
2002-02-24 0:41 ` Kim F. Storm
2002-03-03 17:25 ` Tak Ota
2002-03-04 23:41 ` Richard Stallman
2002-03-05 6:19 ` Tak Ota
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200202221938.g1MJcbn31112@rum.cs.yale.edu \
--to=monnier+gnu/emacs@rum.cs.yale.edu \
--cc=emacs-devel@gnu.org \
--cc=rms@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).