From 6105399dcc36b1b20c95378f895092ab36f7e986 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Mon, 30 May 2011 14:14:19 -0300 Subject: [PATCH] * bytecomp.el (byte-compile-defvar): Add note about quoted lambda. --- lisp/emacs-lisp/bytecomp.el | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el index f0f59123aa9..0dae6748c24 100644 --- a/lisp/emacs-lisp/bytecomp.el +++ b/lisp/emacs-lisp/bytecomp.el @@ -4155,6 +4155,8 @@ binding slots have been popped." (if (eq fun 'defconst) ;; `defconst' sets `var' unconditionally. (let ((tmp (make-symbol "defconst-tmp-var"))) + ;; Quote with `quote' to prevent byte-compiling the body, + ;; which would lead to an inf-loop. `(funcall '(lambda (,tmp) (defconst ,var ,tmp)) ,value)) ;; `defvar' sets `var' only when unbound. -- 2.11.4.GIT