bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#14422: 24.3; Eager Macro Expansion


From: Stefan Monnier
Subject: bug#14422: 24.3; Eager Macro Expansion
Date: Mon, 03 Jun 2013 11:29:30 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

> The behavior is still different in a few other cases (where eager macro
> expansion is not performed, typically M-C-x and things like that), but
> I hope to reduce/eliminate them at some point.

It just occurred to me that the patch below which I just installed
covers several of those cases.


        Stefan


--- lisp/emacs-lisp/lisp-mode.el        2013-05-29 14:14:16 +0000
+++ lisp/emacs-lisp/lisp-mode.el        2013-06-03 14:23:31 +0000
@@ -809,6 +809,7 @@
 (defun eval-sexp-add-defvars (exp &optional pos)
   "Prepend EXP with all the `defvar's that precede it in the buffer.
 POS specifies the starting position where EXP was found and defaults to point."
+  (setq exp (macroexpand-all exp))      ;Eager macro-expansion.
   (if (not lexical-binding)
       exp
     (save-excursion






reply via email to

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