aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lisp/emacs-lisp/seq.el4
1 files changed, 2 insertions, 2 deletions
diff --git a/lisp/emacs-lisp/seq.el b/lisp/emacs-lisp/seq.el
index b8647ec93ec..0050ff0a303 100644
--- a/lisp/emacs-lisp/seq.el
+++ b/lisp/emacs-lisp/seq.el
@@ -50,12 +50,12 @@ Evaluate BODY with VAR bound to each element of SEQ, in turn.
50 50
51\(fn (VAR SEQ) BODY...)" 51\(fn (VAR SEQ) BODY...)"
52 (declare (indent 1) (debug ((symbolp form &optional form) body))) 52 (declare (indent 1) (debug ((symbolp form &optional form) body)))
53 (let ((is-list (make-symbol "is-list")) 53 (let ((length (make-symbol "length"))
54 (seq (make-symbol "seq")) 54 (seq (make-symbol "seq"))
55 (index (make-symbol "index"))) 55 (index (make-symbol "index")))
56 `(let* ((,seq ,(cadr spec)) 56 `(let* ((,seq ,(cadr spec))
57 (,length (if (listp ,seq) nil (seq-length ,seq))) 57 (,length (if (listp ,seq) nil (seq-length ,seq)))
58 (,index (if ,is-list ,seq 0))) 58 (,index (if ,length 0 ,seq)))
59 (while (if ,length 59 (while (if ,length
60 (< ,index ,length) 60 (< ,index ,length)
61 (consp ,index)) 61 (consp ,index))