From 4acab5d751ad411ed637e8a46dc3280db0ddcabd Mon Sep 17 00:00:00 2001 From: Matus Goljer Date: Fri, 28 Aug 2015 15:24:53 +0200 Subject: [PATCH] Use reverse instead of explicit iteration. --- dash.el | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/dash.el b/dash.el index 951ca10..6ecf100 100644 --- a/dash.el +++ b/dash.el @@ -1783,8 +1783,7 @@ Alias: `-uniq'" "Return a new list containing the elements of LIST1 and elements of LIST2 that are not in LIST1. The test for equality is done with `equal', or with `-compare-fn' if that's non-nil." - (let (result) - (--each list (!cons it result)) + (let ((result (reverse list))) (--each list2 (unless (-contains? result it) (!cons it result))) (nreverse result)))