[8187] in Athena Bugs

home help back first fref pref prev next nref lref last post

emacs keyboard-macro naming bug

daemon@ATHENA.MIT.EDU (kkkken@ATHENA.MIT.EDU)
Fri Sep 13 16:24:22 1991

From: kkkken@ATHENA.MIT.EDU
Date: Fri, 13 Sep 91 16:24:53 -0400
To: bugs@ATHENA.MIT.EDU


If you try to name and insert a keyboard macro (using M-x
name-last-kbd-macro and insert-kbd-macro), and give it a name that's a
number (or starts with a digit), it produces emacs-lisp code that
loses.  Here's how to see the problem:

C-x ( h e l l o C-x )			(define the macro)
M-x name-last-kbd-macro RET 123 RET	(name the macro as a number)
M-x insert-kbd-macro RET 123 RET	(have emacs generate code)

You get this:

(fset '\123
   "hello")

This doesn't interpret.  You get:

   Wrong type argument: symbolp, 123

The fix is easy.  The code generated should have been:

(fset (intern "123")
   "hello")

-Ken


home help back first fref pref prev next nref lref last post