emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/crux 3e03d72 049/112: Don't use dash.el function (#34)


From: ELPA Syncer
Subject: [nongnu] elpa/crux 3e03d72 049/112: Don't use dash.el function (#34)
Date: Wed, 11 Aug 2021 09:57:51 -0400 (EDT)

branch: elpa/crux
commit 3e03d7272f99939eb669c59f5b8843912e1e49cf
Author: Syohei YOSHIDA <syohex@gmail.com>
Commit: Bozhidar Batsov <bozhidar.batsov@gmail.com>

    Don't use dash.el function (#34)
---
 crux.el | 22 ++++++++++------------
 1 file changed, 10 insertions(+), 12 deletions(-)

diff --git a/crux.el b/crux.el
index 157b07b..ed3e306 100644
--- a/crux.el
+++ b/crux.el
@@ -234,12 +234,11 @@ point reaches the beginning or end of the buffer, stop 
there."
   (pcase-let* ((origin (point))
                (`(,beg . ,end) (crux-get-positions-of-line-or-region))
                (region (buffer-substring-no-properties beg end)))
-    (-dotimes arg
-      (lambda (n)
-        (goto-char end)
-        (newline)
-        (insert region)
-        (setq end (point))))
+    (dotimes (_i arg)
+      (goto-char end)
+      (newline)
+      (insert region)
+      (setq end (point)))
     (goto-char (+ origin (* (length region) arg) arg))))
 
 (defun crux-duplicate-and-comment-current-line-or-region (arg)
@@ -252,12 +251,11 @@ point reaches the beginning or end of the buffer, stop 
there."
                (region (buffer-substring-no-properties beg end)))
     (comment-or-uncomment-region beg end)
     (setq end (line-end-position))
-    (-dotimes arg
-      (lambda (n)
-        (goto-char end)
-        (newline)
-        (insert region)
-        (setq end (point))))
+    (dotimes (_ arg)
+      (goto-char end)
+      (newline)
+      (insert region)
+      (setq end (point)))
     (goto-char (+ origin (* (length region) arg) arg))))
 
 (defun crux-rename-file-and-buffer ()



reply via email to

[Prev in Thread] Current Thread [Next in Thread]