[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/dash 6d43c4f 235/426: Fix switched around doc strings f
From: |
Phillip Lord |
Subject: |
[elpa] externals/dash 6d43c4f 235/426: Fix switched around doc strings for -find-index/indices |
Date: |
Tue, 04 Aug 2015 19:37:58 +0000 |
branch: externals/dash
commit 6d43c4f9871da9661a44082cd330c651686d402e
Author: Magnar Sveen <address@hidden>
Commit: Magnar Sveen <address@hidden>
Fix switched around doc strings for -find-index/indices
---
README.md | 10 +++++-----
dash.el | 10 +++++-----
2 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/README.md b/README.md
index c7b6068..d4431e4 100644
--- a/README.md
+++ b/README.md
@@ -715,8 +715,9 @@ element `elem`, in ascending order.
#### -find-index `(pred list)`
-Return the indices of all elements in `list` satisfying the
-predicate `pred`, in ascending order.
+Take a predicate `pred` and a `list` and return the index of the
+first element in the list satisfying the predicate, or nil if
+there is no such element.
```cl
(-find-index 'even? '(2 4 1 6 3 3 5 8)) ;; => 0
@@ -726,9 +727,8 @@ predicate `pred`, in ascending order.
#### -find-indices `(pred list)`
-Take a predicate `pred` and a `list` and return the index of the
-first element in the list satisfying the predicate, or nil if
-there is no such element.
+Return the indices of all elements in `list` satisfying the
+predicate `pred`, in ascending order.
```cl
(-find-indices 'even? '(2 4 1 6 3 3 5 8)) ;; => '(0 1 3 7)
diff --git a/dash.el b/dash.el
index 9e803c6..9e6edd8 100644
--- a/dash.el
+++ b/dash.el
@@ -709,9 +709,8 @@ element ELEM, in ascending order."
(-find-indices (-partial 'equal elem) list))
(defun -find-indices (pred list)
- "Take a predicate PRED and a LIST and return the index of the
-first element in the list satisfying the predicate, or nil if
-there is no such element."
+ "Return the indices of all elements in LIST satisfying the
+predicate PRED, in ascending order."
(let ((i 0))
(apply 'append (--map-indexed (when (funcall pred it) (list it-index))
list))))
@@ -720,8 +719,9 @@ there is no such element."
`(-find-indices (lambda (it) ,form) ,list))
(defun -find-index (pred list)
- "Return the indices of all elements in LIST satisfying the
-predicate PRED, in ascending order."
+ "Take a predicate PRED and a LIST and return the index of the
+first element in the list satisfying the predicate, or nil if
+there is no such element."
(car (-find-indices pred list)))
(defmacro --find-index (form list)
- [elpa] externals/dash 6eeb692 236/426: Provide an implementation of function composition., (continued)
- [elpa] externals/dash 6eeb692 236/426: Provide an implementation of function composition., Phillip Lord, 2015/08/04
- [elpa] externals/dash 1812a17 226/426: Complete dash and dash-functional split, Phillip Lord, 2015/08/04
- [elpa] externals/dash 13e0a35 240/426: Release 2.2.0, Phillip Lord, 2015/08/04
- [elpa] externals/dash 5232399 238/426: Merge pull request #50 from kurisuwhyte/master, Phillip Lord, 2015/08/04
- [elpa] externals/dash 87c8b91 232/426: Add indexing operations, Phillip Lord, 2015/08/04
- [elpa] externals/dash 6d20aa0 241/426: If has an indent function 2, not 1, Phillip Lord, 2015/08/04
- [elpa] externals/dash 8e2422a 239/426: Add Christina Whyte (@kurisuwhyte) to list of contributors, Phillip Lord, 2015/08/04
- [elpa] externals/dash 1e2bd96 233/426: Merge pull request #48 from Fuco1/index-operations, Phillip Lord, 2015/08/04
- [elpa] externals/dash d1913c6 210/426: Merge pull request #41 from Wilfred/master, Phillip Lord, 2015/08/04
- [elpa] externals/dash b4d84de 243/426: Add debug declarations for `-when-let`s and `-if-let`s, Phillip Lord, 2015/08/04
- [elpa] externals/dash 6d43c4f 235/426: Fix switched around doc strings for -find-index/indices,
Phillip Lord <=
- [elpa] externals/dash 459322d 244/426: Update docs, Phillip Lord, 2015/08/04
- [elpa] externals/dash 9936885 245/426: Merge pull request #51 from Fuco1/debug-decl, Phillip Lord, 2015/08/04
- [elpa] externals/dash 0f4cae9 249/426: Improve docs, Phillip Lord, 2015/08/04
- [elpa] externals/dash 23ab726 227/426: Improve formatting of docs, Phillip Lord, 2015/08/04
- [elpa] externals/dash f4ba8db 252/426: Add -snoc, Phillip Lord, 2015/08/04
- [elpa] externals/dash bf85b21 242/426: Change &optional branches to &rest branches in `-if-let`s, Phillip Lord, 2015/08/04
- [elpa] externals/dash bf99147 247/426: Fix `-tree-mapreduce-from` test & reformat the tests, Phillip Lord, 2015/08/04
- [elpa] externals/dash 75efb60 246/426: Add tree map/reduce, Phillip Lord, 2015/08/04
- [elpa] externals/dash 2ee84cb 251/426: Release 2.3.0, Phillip Lord, 2015/08/04
- [elpa] externals/dash ab727ba 257/426: Correct anchors for links starting with '!', Phillip Lord, 2015/08/04