aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lisp/emacs-lisp/bytecomp.el7
1 files changed, 4 insertions, 3 deletions
diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el
index 688f8cfa4db..5479e6536a3 100644
--- a/lisp/emacs-lisp/bytecomp.el
+++ b/lisp/emacs-lisp/bytecomp.el
@@ -2796,14 +2796,15 @@ If FORM is a lambda or a macro, byte-compile it as a function."
2796 ;; Expand macros. 2796 ;; Expand macros.
2797 (setq fun (byte-compile-preprocess fun)) 2797 (setq fun (byte-compile-preprocess fun))
2798 (setq fun (byte-compile-top-level fun nil 'eval)) 2798 (setq fun (byte-compile-top-level fun nil 'eval))
2799 (if macro (push 'macro fun))
2800 (if (symbolp form) 2799 (if (symbolp form)
2801 ;; byte-compile-top-level returns an *expression* equivalent to the 2800 ;; byte-compile-top-level returns an *expression* equivalent to the
2802 ;; `fun' expression, so we need to evaluate it, tho normally 2801 ;; `fun' expression, so we need to evaluate it, tho normally
2803 ;; this is not needed because the expression is just a constant 2802 ;; this is not needed because the expression is just a constant
2804 ;; byte-code object, which is self-evaluating. 2803 ;; byte-code object, which is self-evaluating.
2805 (fset form (eval fun t)) 2804 (setq fun (eval fun t)))
2806 fun))))))) 2805 (if macro (push 'macro fun))
2806 (if (symbolp form) (fset form fun))
2807 fun))))))
2807 2808
2808(defun byte-compile-sexp (sexp) 2809(defun byte-compile-sexp (sexp)
2809 "Compile and return SEXP." 2810 "Compile and return SEXP."