From 4c6272373d4e5a6fbb8668f4980bbafbdc28405e Mon Sep 17 00:00:00 2001 From: Andrea Corallo Date: Sun, 8 Sep 2019 17:13:48 +0200 Subject: [PATCH] add defconst support --- lisp/emacs-lisp/comp.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lisp/emacs-lisp/comp.el b/lisp/emacs-lisp/comp.el index c5c36e9eda8..12c8ca63699 100644 --- a/lisp/emacs-lisp/comp.el +++ b/lisp/emacs-lisp/comp.el @@ -283,9 +283,9 @@ Put PREFIX in front of it." (byte-compile-file filename) (setf (comp-ctxt-top-level-defvars comp-ctxt) (reverse (mapcar (lambda (x) - (if (eq (car x) 'defvar) - (cdr x) - (cl-assert nil))) + (ecase (car x) + ('defvar (cdr x)) + ('defconst (cdr x)))) byte-to-native-top-level-forms))) (cl-loop for (name lap bytecode) in byte-to-native-output for lambda-list = (aref bytecode 0) -- 2.39.5