summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lisp/ChangeLog4
-rw-r--r--lisp/pcvs-util.el8
2 files changed, 9 insertions, 3 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 79a74b68488..9f51e4a0ab8 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,7 @@
+2008-04-07 Stefan Monnier <monnier@iro.umontreal.ca>
+
+ * pcvs-util.el (cvs-map): Avoid recursion :-(
+
2008-04-07 Glenn Morris <rgm@gnu.org>
* calendar/calendar.el (calendar-mode-map): Replace use of kbd.
diff --git a/lisp/pcvs-util.el b/lisp/pcvs-util.el
index bd4efef8d55..1cbe72796c2 100644
--- a/lisp/pcvs-util.el
+++ b/lisp/pcvs-util.el
@@ -51,9 +51,11 @@
(unless (member x ys) (push x zs)))))
(defun cvs-map (-cvs-map-f &rest -cvs-map-ls)
- (unless (cvs-every 'null -cvs-map-ls)
- (cons (apply -cvs-map-f (mapcar 'car -cvs-map-ls))
- (apply 'cvs-map -cvs-map-f (mapcar 'cdr -cvs-map-ls)))))
+ (let ((accum ()))
+ (while (not (cvs-every 'null -cvs-map-ls))
+ (push (apply -cvs-map-f (mapcar 'car -cvs-map-ls)) accum)
+ (setq -cvs-map-ls (mapcar 'cdr -cvs-map-ls)))
+ (nreverse accum)))
(defun cvs-first (l &optional n)
(if (null n) (car l)