From 51d81a5c4a523e56f9af83b733d5266442ba37f4 Mon Sep 17 00:00:00 2001 From: "Basil L. Contovounesios" Date: Sat, 6 Feb 2021 15:19:40 +0000 Subject: [PATCH] Avoid using dash.el functions in macro bodies * dash-functional.el (-cut): Prepare for this macro's inclusion in dash.el by replacing any uses of dash.el functions that are not defined at byte-compile-time with corresponding macros (#356). --- dash-functional.el | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/dash-functional.el b/dash-functional.el index a0965ad..f131f7b 100644 --- a/dash-functional.el +++ b/dash-functional.el @@ -87,8 +87,10 @@ Arguments denoted by <> will be left unspecialized. See SRFI-26 for detailed description." (let* ((i 0) - (args (mapcar (lambda (_) (setq i (1+ i)) (make-symbol (format "D%d" i))) - (-filter (-partial 'eq '<>) params)))) + (args (--keep (when (eq it '<>) + (setq i (1+ i)) + (make-symbol (format "D%d" i))) + params))) `(lambda ,args ,(let ((body (--map (if (eq it '<>) (pop args) it) params))) (if (eq (car params) '<>)