emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] master 6ff8b77: * lisp/emacs-lisp/cconv.el (cconv-convert)


From: Stefan Monnier
Subject: [Emacs-diffs] master 6ff8b77: * lisp/emacs-lisp/cconv.el (cconv-convert): Fix compiling compiled code
Date: Fri, 2 Feb 2018 10:29:11 -0500 (EST)

branch: master
commit 6ff8b7749fcc96b79489f73500bcd4722263383c
Author: Stefan Monnier <address@hidden>
Commit: Stefan Monnier <address@hidden>

    * lisp/emacs-lisp/cconv.el (cconv-convert): Fix compiling compiled code
    
    Don't conv-convert the docstring arg of defvar/defconst.
---
 lisp/emacs-lisp/cconv.el | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/lisp/emacs-lisp/cconv.el b/lisp/emacs-lisp/cconv.el
index 02fe794..ca46dbb 100644
--- a/lisp/emacs-lisp/cconv.el
+++ b/lisp/emacs-lisp/cconv.el
@@ -449,8 +449,11 @@ places where they originally did not directly appear."
                                        ;defconst, defvar
     (`(,(and sym (or `defconst `defvar)) ,definedsymbol . ,forms)
      `(,sym ,definedsymbol
-            . ,(mapcar (lambda (form) (cconv-convert form env extend))
-                       forms)))
+            . ,(when (consp forms)
+                 (cons (cconv-convert (car forms) env extend)
+                       ;; The rest (i.e. docstring, of any) is not evaluated,
+                       ;; and may be an invalid expression (e.g. ($# . 678)).
+                       (cdr forms)))))
 
                                        ;condition-case
     ((and `(condition-case ,var ,protected-form . ,handlers)



reply via email to

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