[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/dash 4e6a965 294/426: Still better debug declarations
From: |
Phillip Lord |
Subject: |
[elpa] externals/dash 4e6a965 294/426: Still better debug declarations |
Date: |
Tue, 04 Aug 2015 19:38:23 +0000 |
branch: externals/dash
commit 4e6a965269f4e1d721e8a253bbc41f3628e9a0a0
Author: Matus Goljer <address@hidden>
Commit: Matus Goljer <address@hidden>
Still better debug declarations
---
dash.el | 84 +++++++++++++++++++++++++++++++-------------------------------
1 files changed, 42 insertions(+), 42 deletions(-)
diff --git a/dash.el b/dash.el
index 0eb9360..b38c1d3 100644
--- a/dash.el
+++ b/dash.el
@@ -73,7 +73,7 @@ special values."
(defmacro --each-while (list pred &rest body)
"Anaphoric form of `-each-while'."
- (declare (debug (form sexp body))
+ (declare (debug (form form body))
(indent 2))
(let ((l (make-symbol "list"))
(c (make-symbol "continue")))
@@ -93,7 +93,7 @@ Returns nil, used for side-effects only."
(defmacro --dotimes (num &rest body)
"Repeatedly executes BODY (presumably for side-effects) with `it` bound to
integers from 0 through n-1."
- (declare (debug (integerp body))
+ (declare (debug (form body))
(indent 1))
`(let ((it 0))
(while (< it ,num)
@@ -112,12 +112,12 @@ Returns nil, used for side-effects only."
(defmacro --map (form list)
"Anaphoric form of `-map'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(mapcar (lambda (it) ,form) ,list))
(defmacro --reduce-from (form initial-value list)
"Anaphoric form of `-reduce-from'."
- (declare (debug (sexp form form)))
+ (declare (debug (form form form)))
`(let ((acc ,initial-value))
(--each ,list (setq acc ,form))
acc))
@@ -134,7 +134,7 @@ exposed as `acc`."
(defmacro --reduce (form list)
"Anaphoric form of `-reduce'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((lv (make-symbol "list-value")))
`(let ((,lv ,list))
(if ,lv
@@ -166,7 +166,7 @@ operation associates from right instead of from left."
(defmacro --reduce-r-from (form initial-value list)
"Anaphoric version of `-reduce-r-from'."
- (declare (debug (sexp form form)))
+ (declare (debug (form form form)))
`(-reduce-r-from (lambda (&optional it acc) ,form) ,initial-value ,list))
(defun -reduce-r (fn list)
@@ -188,12 +188,12 @@ associates from right instead of from left."
(defmacro --reduce-r (form list)
"Anaphoric version of `-reduce-r'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(-reduce-r (lambda (&optional it acc) ,form) ,list))
(defmacro --filter (form list)
"Anaphoric form of `-filter'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((r (make-symbol "result")))
`(let (,r)
(--each ,list (when ,form (!cons it ,r)))
@@ -210,7 +210,7 @@ Alias: `-select'"
(defmacro --remove (form list)
"Anaphoric form of `-remove'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(--filter (not ,form) ,list))
(defun -remove (pred list)
@@ -224,7 +224,7 @@ Alias: `-reject'"
(defmacro --keep (form list)
"Anaphoric form of `-keep'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((r (make-symbol "result"))
(m (make-symbol "mapped")))
`(let (,r)
@@ -237,7 +237,7 @@ Alias: `-reject'"
(defmacro --map-when (pred rep list)
"Anaphoric form of `-map-when'."
- (declare (debug (sexp sexp form)))
+ (declare (debug (form form form)))
(let ((r (make-symbol "result")))
`(let (,r)
(--each ,list (!cons (if ,pred ,rep it) ,r))
@@ -245,7 +245,7 @@ Alias: `-reject'"
(defmacro --map-indexed (form list)
"Anaphoric form of `-map-indexed'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((r (make-symbol "result")))
`(let (,r)
(--each ,list
@@ -279,7 +279,7 @@ through the REP function."
(defmacro --mapcat (form list)
"Anaphoric form of `-mapcat'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(apply 'append (--map ,form ,list)))
(defun -mapcat (fn list)
@@ -305,7 +305,7 @@ If ELEMENTS is non nil, append these to the list as well."
(defmacro --first (form list)
"Anaphoric form of `-first'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((n (make-symbol "needle")))
`(let (,n)
(--each-while ,list (not ,n)
@@ -320,7 +320,7 @@ To get the first item in the list no questions asked, use
`car'."
(defmacro --last (form list)
"Anaphoric form of `-last'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((n (make-symbol "needle")))
`(let (,n)
(--each ,list
@@ -340,7 +340,7 @@ To get the first item in the list no questions asked, use
`car'."
(defmacro --count (pred list)
"Anaphoric form of `-count'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((r (make-symbol "result")))
`(let ((,r 0))
(--each ,list (when ,pred (setq ,r (1+ ,r))))
@@ -355,7 +355,7 @@ To get the first item in the list no questions asked, use
`car'."
(defmacro --any? (form list)
"Anaphoric form of `-any?'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(---truthy? (--first ,form ,list)))
(defun -any? (pred list)
@@ -374,7 +374,7 @@ Alias: `-some?'"
(defmacro --all? (form list)
"Anaphoric form of `-all?'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((a (make-symbol "all")))
`(let ((,a t))
(--each-while ,list ,a (setq ,a ,form))
@@ -396,7 +396,7 @@ Alias: `-every?'"
(defmacro --none? (form list)
"Anaphoric form of `-none?'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(--all? (not ,form) ,list))
(defun -none? (pred list)
@@ -408,7 +408,7 @@ Alias: `-every?'"
(defmacro --only-some? (form list)
"Anaphoric form of `-only-some?'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((y (make-symbol "yes"))
(n (make-symbol "no")))
`(let (,y ,n)
@@ -462,7 +462,7 @@ FROM or TO may be negative."
(defmacro --take-while (form list)
"Anaphoric form of `-take-while'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((r (make-symbol "result")))
`(let (,r)
(--each-while ,list ,form (!cons it ,r))
@@ -474,7 +474,7 @@ FROM or TO may be negative."
(defmacro --drop-while (form list)
"Anaphoric form of `-drop-while'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((l (make-symbol "list")))
`(let ((,l ,list))
(while (and ,l (let ((it (car ,l))) ,form))
@@ -518,7 +518,7 @@ The time complexity is O(n)."
(defmacro --update-at (n form list)
"Anaphoric version of `-update-at'."
- (declare (debug (integerp sexp form)))
+ (declare (debug (form form form)))
`(-update-at ,n (lambda (it) ,form) ,list))
(defun -remove-at (n list)
@@ -541,7 +541,7 @@ from INDICES."
(defmacro --split-with (pred list)
"Anaphoric form of `-split-with'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((l (make-symbol "list"))
(r (make-symbol "result"))
(c (make-symbol "continue")))
@@ -574,7 +574,7 @@ See also `-split-when'."
(defmacro --split-when (form list)
"Anaphoric version of `-split-when'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(-split-when (lambda (it) ,form) ,list))
(defun -split-when (fn list)
@@ -597,7 +597,7 @@ This function can be thought of as a generalization of
(defmacro --separate (form list)
"Anaphoric form of `-separate'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((y (make-symbol "yes"))
(n (make-symbol "no")))
`(let (,y ,n)
@@ -646,7 +646,7 @@ those items are discarded."
(defmacro --partition-by (form list)
"Anaphoric form of `-partition-by'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((r (make-symbol "result"))
(s (make-symbol "sublist"))
(v (make-symbol "value"))
@@ -677,7 +677,7 @@ those items are discarded."
(defmacro --partition-by-header (form list)
"Anaphoric form of `-partition-by-header'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((r (make-symbol "result"))
(s (make-symbol "sublist"))
(h (make-symbol "header-value"))
@@ -715,7 +715,7 @@ those items are discarded."
(defmacro --group-by (form list)
"Anaphoric form of `-group-by'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
(let ((l (make-symbol "list"))
(v (make-symbol "value"))
(k (make-symbol "key"))
@@ -769,7 +769,7 @@ elements of LIST. Keys are compared by `equal'."
"Anaphoric form of `-zip-with'.
The elements in list1 is bound as `it`, the elements in list2 as `other`."
- (declare (debug (sexp form form)))
+ (declare (debug (form form form)))
(let ((r (make-symbol "result"))
(l1 (make-symbol "list1"))
(l2 (make-symbol "list2")))
@@ -827,7 +827,7 @@ predicate PRED, in ascending order."
(defmacro --find-indices (form list)
"Anaphoric version of `-find-indices'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(-find-indices (lambda (it) ,form) ,list))
(defun -find-index (pred list)
@@ -838,7 +838,7 @@ there is no such element."
(defmacro --find-index (form list)
"Anaphoric version of `-find-index'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(-find-index (lambda (it) ,form) ,list))
(defun -find-last-index (pred list)
@@ -1084,7 +1084,7 @@ if the first element should sort before the second."
(defmacro --sort (form list)
"Anaphoric form of `-sort'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(-sort (lambda (it other) ,form) ,list))
(defun -list (&rest args)
@@ -1138,14 +1138,14 @@ comparing them."
"Anaphoric version of `-max-by'.
The items for the comparator form are exposed as \"it\" and \"other\"."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(-max-by (lambda (it other) ,form) ,list))
(defmacro --min-by (form list)
"Anaphoric version of `-min-by'.
The items for the comparator form are exposed as \"it\" and \"other\"."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(-min-by (lambda (it other) ,form) ,list))
(defun -iterate (fun init n)
@@ -1163,7 +1163,7 @@ N is the length of the returned list."
(defmacro --iterate (form init n)
"Anaphoric version of `-iterate'."
- (declare (debug (sexp form form)))
+ (declare (debug (form form form)))
`(-iterate (lambda (it) ,form) ,init ,n))
(defun -unfold (fun seed)
@@ -1184,7 +1184,7 @@ the new seed."
(defmacro --unfold (form seed)
"Anaphoric version of `-unfold'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(-unfold (lambda (it) ,form) ,seed))
(defun -cons-pair? (con)
@@ -1227,7 +1227,7 @@ but is twice as fast as it only traverse the structure
once."
(defmacro --tree-mapreduce-from (form folder init-value tree)
"Anaphoric form of `-tree-mapreduce-from'."
- (declare (debug (sexp sexp form form)))
+ (declare (debug (form form form form)))
`(-tree-mapreduce-from (lambda (it) ,form) (lambda (it acc) ,folder)
,init-value ,tree))
(defun -tree-mapreduce (fn folder tree)
@@ -1249,7 +1249,7 @@ but is twice as fast as it only traverse the structure
once."
(defmacro --tree-mapreduce (form folder tree)
"Anaphoric form of `-tree-mapreduce'."
- (declare (debug (sexp sexp form)))
+ (declare (debug (form form form)))
`(-tree-mapreduce (lambda (it) ,form) (lambda (it acc) ,folder) ,tree))
(defun -tree-map (fn tree)
@@ -1263,7 +1263,7 @@ but is twice as fast as it only traverse the structure
once."
(defmacro --tree-map (form tree)
"Anaphoric form of `-tree-map'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(-tree-map (lambda (it) ,form) ,tree))
(defun -tree-reduce-from (fn init-value tree)
@@ -1284,7 +1284,7 @@ two elements."
(defmacro --tree-reduce-from (form init-value tree)
"Anaphoric form of `-tree-reduce-from'."
- (declare (debug (sexp form form)))
+ (declare (debug (form form form)))
`(-tree-reduce-from (lambda (it acc) ,form) ,init-value ,tree))
(defun -tree-reduce (fn tree)
@@ -1304,7 +1304,7 @@ See `-reduce-r' for how exactly are lists of zero or one
element handled."
(defmacro --tree-reduce (form tree)
"Anaphoric form of `-tree-reduce'."
- (declare (debug (sexp form)))
+ (declare (debug (form form)))
`(-tree-reduce (lambda (it acc) ,form) ,tree))
(defun -clone (list)
- [elpa] externals/dash 63ec298 308/426: Merge pull request #92 from Fuco1/outer-product, (continued)
- [elpa] externals/dash 63ec298 308/426: Merge pull request #92 from Fuco1/outer-product, Phillip Lord, 2015/08/04
- [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 <=
- [elpa] externals/dash dab0d1c 384/426: Merge pull request #107 from fbergroth/workaround-byte-compiler, Phillip Lord, 2015/08/04
- [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