emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[elpa] externals/relint 92b3cfa058 09/10: Eliminate a big memq in evalua


From: ELPA Syncer
Subject: [elpa] externals/relint 92b3cfa058 09/10: Eliminate a big memq in evaluator
Date: Sat, 28 Dec 2024 15:58:51 -0500 (EST)

branch: externals/relint
commit 92b3cfa0589394603d034c00fa04e36e8d2f5012
Author: Mattias EngdegÄrd <mattiase@acm.org>
Commit: Mattias EngdegÄrd <mattiase@acm.org>

    Eliminate a big memq in evaluator
---
 relint.el | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/relint.el b/relint.el
index c573c70e60..8bcf08d01d 100644
--- a/relint.el
+++ b/relint.el
@@ -522,6 +522,8 @@ or (NAME val VAL), for values.")
 (defvar relint--eval-mutables nil
   "List of local variables mutable in the current evaluation context.")
 
+(eval-and-compile
+
 (defconst relint--safe-functions
   '(cons list append
     concat
@@ -577,6 +579,8 @@ like `case-fold-search').
 More functions could be added if there is evidence that it would
 help in evaluating more regexp strings.")
 
+)
+
 (defconst relint--safe-alternatives
   '((nconc    . append)
     (delete   . remove)
@@ -763,7 +767,7 @@ not be evaluated safely."
         form)
 
        ;; Functions considered safe.
-       ((memq head relint--safe-functions)
+       ((memq head (eval-when-compile relint--safe-functions))
         (let ((args (mapcar #'relint--eval body)))
           ;; Catching all errors isn't wonderful, but sometimes a global
           ;; variable argument has an unsuitable default value which is



reply via email to

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