[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/dash dab0d1c 384/426: Merge pull request #107 from fber
From: |
Phillip Lord |
Subject: |
[elpa] externals/dash dab0d1c 384/426: Merge pull request #107 from fbergroth/workaround-byte-compiler |
Date: |
Tue, 04 Aug 2015 19:39:05 +0000 |
branch: externals/dash
commit dab0d1c6c5a1e56c3c938fcca13398774f547bd8
Merge: faeb61a c40fa44
Author: Magnar Sveen <address@hidden>
Commit: Magnar Sveen <address@hidden>
Merge pull request #107 from fbergroth/workaround-byte-compiler
Work around byte compiler
---
dash.el | 11 ++++++-----
dev/test-byte-compile.el | 8 ++++++++
run-tests.sh | 9 ++++++++-
3 files changed, 22 insertions(+), 6 deletions(-)
diff --git a/dash.el b/dash.el
index 74dbcab..fd2b779 100644
--- a/dash.el
+++ b/dash.el
@@ -969,7 +969,7 @@ See also: `-table-flat'"
(while (car last-list)
(let ((item (apply fn (-map 'car lists))))
(push item (car re))
- (pop (car lists))
+ (setcar lists (cdar lists)) ;; silence byte compiler
(dash--table-carry lists restore-lists re)))
(nreverse (car (last re)))))
@@ -1500,11 +1500,12 @@ Note: binding is done according to `-let*'."
(declare (debug ((&rest (sexp form)) form body))
(indent 2))
(->> vars-vals
- (-mapcat (-lambda ((pat src)) (dash--match pat src)))
- (-reduce-r-from
- (-lambda ((var val) memo)
+ (--mapcat (dash--match (car it) (cadr it)))
+ (--reduce-r-from
+ (let ((var (car it))
+ (val (cadr it)))
`(let ((,var ,val))
- (if ,var ,memo ,@else)))
+ (if ,var ,acc ,@else)))
then)))
(defmacro -if-let (var-val then &rest else)
diff --git a/dev/test-byte-compile.el b/dev/test-byte-compile.el
new file mode 100644
index 0000000..8d9905e
--- /dev/null
+++ b/dev/test-byte-compile.el
@@ -0,0 +1,8 @@
+(require 'ert)
+
+(ert-deftest dash-byte-compile ()
+ (let* ((cmd "emacs --quick --batch -f batch-byte-compile dash.el")
+ (res (shell-command-to-string cmd))
+ (elc (expand-file-name "dash.elc"))
+ (exp (format "Wrote %s\n" elc)))
+ (should (string= res exp))))
diff --git a/run-tests.sh b/run-tests.sh
index a72e077..ce9a011 100755
--- a/run-tests.sh
+++ b/run-tests.sh
@@ -4,4 +4,11 @@ if [ -z "$EMACS" ] ; then
EMACS="emacs"
fi
-$EMACS -batch -l dev/ert.el -l dash.el -l dash-functional.el -l
dev/examples-to-tests.el -l dev/examples.el -f ert-run-tests-batch-and-exit
+$EMACS -batch \
+ -l dev/ert.el \
+ -l dash.el \
+ -l dash-functional.el \
+ -l dev/examples-to-tests.el \
+ -l dev/examples.el \
+ $([[ $EMACS != "emacs23" ]] && echo -l dev/test-byte-compile.el) \
+ -f ert-run-tests-batch-and-exit
- [elpa] externals/dash 00549e4 307/426: Add missing fontification keywords, (continued)
- [elpa] externals/dash 00549e4 307/426: Add missing fontification keywords, Phillip Lord, 2015/08/04
- [elpa] externals/dash 9ebd172 421/426: [-let] Generate differently named symbols for temporary sources (makes, Phillip Lord, 2015/08/04
- [elpa] externals/dash c134705 377/426: Fix compile warning, Phillip Lord, 2015/08/04
- [elpa] externals/dash 40896b8 418/426: Fix the -let debug declaration, Phillip Lord, 2015/08/04
- [elpa] externals/dash 79c23bb 282/426: Merge pull request #70 from Fuco1/debug-decl, Phillip Lord, 2015/08/04
- [elpa] externals/dash 5d25ed2 275/426: Release 2.5.0, Phillip Lord, 2015/08/04
- [elpa] externals/dash 2cc124b 423/426: [-let] Generate better code when skipping conses, Phillip Lord, 2015/08/04
- [elpa] externals/dash b7c2f9a 381/426: Work around byte compiler in -if-let*, Phillip Lord, 2015/08/04
- [elpa] externals/dash b201f0c 281/426: Add debug declarations and move indent declarations into `declare`, Phillip Lord, 2015/08/04
- [elpa] externals/dash 4e6a965 294/426: Still better debug declarations, Phillip Lord, 2015/08/04
- [elpa] externals/dash dab0d1c 384/426: Merge pull request #107 from fbergroth/workaround-byte-compiler,
Phillip Lord <=
- [elpa] externals/dash 446c522 375/426: Release 2.10.0, Phillip Lord, 2015/08/04
- [elpa] externals/dash 2dfd748 298/426: Merge pull request #87 from steventlamb/topic/make_zip_n_ary, Phillip Lord, 2015/08/04
- [elpa] externals/dash a3021eb 313/426: Merge pull request #93 from lunaryorn/patch-1, Phillip Lord, 2015/08/04
- [elpa] externals/dash 8d2227d 380/426: Silence unused variable warning in -table, Phillip Lord, 2015/08/04
- [elpa] externals/dash f5264db 291/426: Merge pull request #77 from Fuco1/split-when, Phillip Lord, 2015/08/04
- [elpa] externals/dash c40fa44 383/426: Exclude byte compilation test on emacs23, Phillip Lord, 2015/08/04
- [elpa] externals/dash f0dd4cc 301/426: Add -annotate, Phillip Lord, 2015/08/04
- [elpa] externals/dash b44140a 288/426: Add -is-prefix/suffix/infix-p, Phillip Lord, 2015/08/04
- [elpa] externals/dash 38ef86e 376/426: Update debug forms for -if-let and -when-let, Phillip Lord, 2015/08/04
- [elpa] externals/dash b308794 416/426: [Fix #73] Add a mention of -filter to -keep docstring, Phillip Lord, 2015/08/04