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

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

[elpa] externals/dash 93e0465 137/316: Remove dependecy `macroexp`


From: ELPA Syncer
Subject: [elpa] externals/dash 93e0465 137/316: Remove dependecy `macroexp`
Date: Mon, 15 Feb 2021 15:57:43 -0500 (EST)

branch: externals/dash
commit 93e0465e0ea1d3fbcb49e84f0663c9be6a988225
Author: citreu <all_but_last@163.com>
Commit: citreu <all_but_last@163.com>

    Remove dependecy `macroexp`
    
    We need to support lower version since `macroexp-let2` was introduced at
    Emacs 24.3
---
 dash.el | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/dash.el b/dash.el
index 411e052..e945fbb 100644
--- a/dash.el
+++ b/dash.el
@@ -1828,12 +1828,12 @@ kv can be any key-value store, such as plist, alist or 
hash-table."
   "Generate extracting KEY from SOURCE for &alist destructuring."
   `(cdr (assoc ,key ,source)))
 
-(require 'macroexp)
-
 (defun dash-expand:&hash? (key source)
   "Generate extracting KEY from SOURCE for &hash? destructuring.
 Similar to &hash but check whether the map is not nil."
-  (macroexp-let2 nil source source `(when ,source (gethash ,key ,source))))
+  (let ((src (make-symbol "src")))
+    `(let ((,src ,source))
+       (when ,src (gethash ,key ,src)))))
 
 (defalias 'dash-expand:&keys 'dash-expand:&plist)
 



reply via email to

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