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

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

[elpa] externals/dash 4b63be1 362/426: Declare --mapcat macro before usi


From: Phillip Lord
Subject: [elpa] externals/dash 4b63be1 362/426: Declare --mapcat macro before using it. #102
Date: Tue, 04 Aug 2015 19:38:54 +0000

branch: externals/dash
commit 4b63be1dce156545bd5f534e91d4a491aa7b06e9
Author: Magnar Sveen <address@hidden>
Commit: Magnar Sveen <address@hidden>

    Declare --mapcat macro before using it. #102
---
 dash.el |   20 ++++++++++----------
 1 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/dash.el b/dash.el
index 078305d..98c0df6 100644
--- a/dash.el
+++ b/dash.el
@@ -287,6 +287,16 @@ Elements are compared using `equal'.
 See also: `-replace-at'"
   (--map-when (equal it old) new list))
 
+(defmacro --mapcat (form list)
+  "Anaphoric form of `-mapcat'."
+  (declare (debug (form form)))
+  `(apply 'append (--map ,form ,list)))
+
+(defun -mapcat (fn list)
+  "Return the concatenation of the result of mapping FN over LIST.
+Thus function FN should return a list."
+  (--mapcat (funcall fn it) list))
+
 (defun -flatten (l)
   "Take a nested list L and return its contents as a single, flat list.
 
@@ -305,16 +315,6 @@ See also: `-flatten'"
   "Return a new list with the concatenation of the elements in the supplied 
LISTS."
   (apply 'append lists))
 
-(defmacro --mapcat (form list)
-  "Anaphoric form of `-mapcat'."
-  (declare (debug (form form)))
-  `(apply 'append (--map ,form ,list)))
-
-(defun -mapcat (fn list)
-  "Return the concatenation of the result of mapping FN over LIST.
-Thus function FN should return a list."
-  (--mapcat (funcall fn it) list))
-
 (defalias '-copy 'copy-sequence
   "Create a shallow copy of LIST.")
 



reply via email to

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