* lisp/progmodes/elisp-mode.el (emacs-lisp-macroexpand): Idem.
Fixes: debbugs:18821
+2014-11-02 Stefan Monnier <monnier@iro.umontreal.ca>
+
+ * emacs-lisp/pp.el (pp-macroexpand-expression): Use macroexpand-1
+ (bug#18821).
+ * progmodes/elisp-mode.el (emacs-lisp-macroexpand): Idem.
+
2014-11-01 Michael R. Mauger <michael@mauger.com>
* sql.el (sql-mode-oracle-font-lock-keywords): Correct regexp
(or (symbolp exp) (macroexp-const-p exp)))
(defun macroexp-quote (v)
- "Returns an expression E such that `(eval E)' is V.
+ "Return an expression E such that `(eval E)' is V.
E is either V or (quote V) depending on whether V evaluates to
itself or not."
"Macroexpand EXPRESSION and pretty-print its value."
(interactive
(list (read--expression "Macroexpand: ")))
- (pp-display-expression (macroexpand expression) "*Pp Macroexpand Output*"))
+ (pp-display-expression (macroexpand-1 expression) "*Pp Macroexpand Output*"))
(defun pp-last-sexp ()
"Read sexp before point. Ignores leading comment characters."
Ignores leading comment characters."
(interactive "P")
(if arg
- (insert (pp-to-string (macroexpand (pp-last-sexp))))
+ (insert (pp-to-string (macroexpand-1 (pp-last-sexp))))
(pp-macroexpand-expression (pp-last-sexp))))
;;; Test cases for quote
(let* ((start (point))
(exp (read (current-buffer)))
;; Compute it before, since it may signal errors.
- (new (macroexpand exp)))
+ (new (macroexpand-1 exp)))
(if (equal exp new)
(message "Not a macro call, nothing to expand")
(delete-region start (point))