[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/corfu 3f5f16c: Use 1-
From: |
Protesilaos Stavrou |
Subject: |
[elpa] externals/corfu 3f5f16c: Use 1- |
Date: |
Fri, 28 May 2021 16:47:12 -0400 (EDT) |
branch: externals/corfu
commit 3f5f16c83788d003cd69a033b98238ddf9322225
Author: Daniel Mendler <mail@daniel-mendler.de>
Commit: Daniel Mendler <mail@daniel-mendler.de>
Use 1-
---
corfu.el | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/corfu.el b/corfu.el
index 714818a..21ac8ea 100644
--- a/corfu.el
+++ b/corfu.el
@@ -540,7 +540,7 @@ Set to nil in order to disable confirmation."
(defun corfu--goto (index)
"Go to candidate with INDEX."
- (setq corfu--index (max -1 (min index (- corfu--total 1)))))
+ (setq corfu--index (max -1 (min index (1- corfu--total)))))
(defun corfu-next ()
"Go to next candidate."
@@ -555,8 +555,8 @@ Set to nil in order to disable confirmation."
(interactive)
(corfu--goto
(if (and corfu-cycle (< corfu--index 0))
- (- corfu--total 1)
- (- corfu--index 1))))
+ (1- corfu--total)
+ (1- corfu--index))))
(defun corfu-scroll-down ()
"Go back by one page."
@@ -576,7 +576,7 @@ Set to nil in order to disable confirmation."
(defun corfu-last ()
"Go to last candidate."
(interactive)
- (corfu--goto (- corfu--total 1)))
+ (corfu--goto (1- corfu--total)))
(defun corfu--restore-on-next-command ()
"Restore window configuration before next command."
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [elpa] externals/corfu 3f5f16c: Use 1-,
Protesilaos Stavrou <=