[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/dash 14673a6 007/439: Use nreverse for performance reas
From: |
Phillip Lord |
Subject: |
[elpa] externals/dash 14673a6 007/439: Use nreverse for performance reasons. |
Date: |
Tue, 04 Aug 2015 20:25:47 +0000 |
branch: externals/dash
commit 14673a66e9048d62e6104550206736ec871f4a85
Author: Magnar Sveen <address@hidden>
Commit: Magnar Sveen <address@hidden>
Use nreverse for performance reasons.
---
bang.el | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/bang.el b/bang.el
index b1bd793..8859802 100644
--- a/bang.el
+++ b/bang.el
@@ -54,7 +54,7 @@ or with `!compare-fn' if that's non-nil."
(while list
(add-to-list 'result (car list) nil !compare-fn)
(setq list (cdr list)))
- (reverse result)))
+ (nreverse result)))
(defun !intersection (list list2)
"Return a new list containing only the elements that are members of both
LIST and LIST2.
@@ -65,7 +65,7 @@ or with `!compare-fn' if that's non-nil."
(when (!contains-p list2 (car list))
(setq result (cons (car list) result)))
(setq list (cdr list)))
- (reverse result)))
+ (nreverse result)))
(defun !difference (list list2)
"Return a new list with only the members of LIST that are not in LIST2.
@@ -76,7 +76,7 @@ or with `!compare-fn' if that's non-nil."
(unless (!contains-p list2 (car list))
(setq result (cons (car list) result)))
(setq list (cdr list)))
- (reverse result)))
+ (nreverse result)))
(defun !contains-p (list element)
"Return whether LIST contains ELEMENT.
- [elpa] branch externals/dash created (now eadb265), Phillip Lord, 2015/08/04
- [elpa] externals/dash 300fbc6 002/439: Remove lisp-comments from README, Phillip Lord, 2015/08/04
- [elpa] externals/dash 9a34da8 004/439: Add config for travis-ci, Phillip Lord, 2015/08/04
- [elpa] externals/dash 302c8ea 001/439: Initial commit., Phillip Lord, 2015/08/04
- [elpa] externals/dash 14673a6 007/439: Use nreverse for performance reasons.,
Phillip Lord <=
- [elpa] externals/dash 7b52951 008/439: Add watchr script to get autotest, Phillip Lord, 2015/08/04
- [elpa] externals/dash 93957f0 006/439: Add travis status icon to README, Phillip Lord, 2015/08/04
- [elpa] externals/dash ad44aee 009/439: Add more tests., Phillip Lord, 2015/08/04
- [elpa] externals/dash 065f76b 005/439: Use ert.el to run on Emacs 23 as well., Phillip Lord, 2015/08/04
- [elpa] externals/dash e720428 010/439: Extract basic iteration form into macro., Phillip Lord, 2015/08/04
- [elpa] externals/dash c229ba8 011/439: Rewrite to anaphoric filter function., Phillip Lord, 2015/08/04
- [elpa] externals/dash d870282 013/439: Add some tests, and fix the bugs they uncovered., Phillip Lord, 2015/08/04
- [elpa] externals/dash 3e0ef58 012/439: !filter can now take either a function or form (anaphoric), Phillip Lord, 2015/08/04
- [elpa] externals/dash b24d056 014/439: !map macro, Phillip Lord, 2015/08/04
- [elpa] externals/dash ed2e447 015/439: !reduce macro, Phillip Lord, 2015/08/04