From: Mattias EngdegÄrd Date: Mon, 10 Apr 2023 09:15:57 +0000 (+0200) Subject: ; Eliminate warning when `dired-map-over-marks` value is unused X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=3faf43137a376631c49b1300e693acc83e20d9c1;p=emacs.git ; Eliminate warning when `dired-map-over-marks` value is unused * lisp/dired.el (dired-map-over-marks): Reformulate. --- diff --git a/lisp/dired.el b/lisp/dired.el index 8e3244356fe..d1471e993a1 100644 --- a/lisp/dired.el +++ b/lisp/dired.el @@ -927,9 +927,9 @@ marked file, return (t FILENAME) instead of (FILENAME)." (lambda () (if ,show-progress (sit-for 0)) (setq results (cons ,body results)))) - (if (< ,arg 0) - (nreverse results) - results)) + (when (< ,arg 0) + (setq results (nreverse results))) + results) ;; non-nil, non-integer, non-marked ARG means use current file: (list ,body)) (let ((regexp (dired-marker-regexp)) next-position)