unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Le Wang <l26wang@gmail.com>
Cc: 9602@debbugs.gnu.org
Subject: bug#9602: kbd macro does not evaluate its parameter
Date: Mon, 26 Sep 2011 00:09:12 -0400	[thread overview]
Message-ID: <jwvaa9s9cc7.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <CAM=K+irfztGMF1-32KmOJJ9g=o4ZT1RKEidniO9iN1GLeFM33Q@mail.gmail.com> (Le Wang's message of "Mon, 26 Sep 2011 09:31:15 +0800")

>  (dolist (abcc '("C-a" "C-b"))
>    (global-unset-key (kbd abcc)))
> Which fails.

Yes, kbd should have been defined as an alias of read-kbd-macro
(i.e. a function) and mark it as pure so the byte-optimizer can
precompute it when applicable.

I know that changing a function into a macro introduces many
compatibility problems, but maybe changing this macro into a function
can be done without problems?


        Stefan





  parent reply	other threads:[~2011-09-26  4:09 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-26  1:31 bug#9602: kbd macro does not evaluate its parameter Le Wang
     [not found] ` <handler.9602.B.131700072132002.ack@debbugs.gnu.org>
2011-09-26  1:47   ` bug#9602: Acknowledgement (kbd macro does not evaluate its parameter) Le Wang
2011-09-26  1:49 ` bug#9602: kbd macro does not evaluate its parameter Drew Adams
2011-09-26  8:01   ` Le Wang
2011-09-26  4:09 ` Stefan Monnier [this message]
2011-09-26  4:45   ` Leo
2011-09-26 13:43     ` Stefan Monnier
2011-09-26 15:52       ` Leo
2011-09-26 16:31         ` Stefan Monnier
2013-02-14  8:17   ` Glenn Morris

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=jwvaa9s9cc7.fsf-monnier+emacs@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=9602@debbugs.gnu.org \
    --cc=l26wang@gmail.com \
    /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).