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

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

[elpa] externals/indent-bars 269774df6d 201/431: Correct bar depth calcu


From: ELPA Syncer
Subject: [elpa] externals/indent-bars 269774df6d 201/431: Correct bar depth calculation corner case
Date: Mon, 16 Sep 2024 12:59:29 -0400 (EDT)

branch: externals/indent-bars
commit 269774df6d5030832d04c5cf067d7a3a2568a46f
Author: JD Smith <93749+jdtsmith@users.noreply.github.com>
Commit: JD Smith <93749+jdtsmith@users.noreply.github.com>

    Correct bar depth calculation corner case
---
 indent-bars.el | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/indent-bars.el b/indent-bars.el
index 20f0d2001b..68d48df3f5 100644
--- a/indent-bars.el
+++ b/indent-bars.el
@@ -630,9 +630,7 @@ font-lock properties."
   "Number of possible bars for initial blank string of length LEN.
 Note that the first bar is expected at `indent-bars-starting-column'."
   (setq len (- len indent-bars--offset))
-  (cond ((>= len indent-bars-spacing) (/ (1+ len) indent-bars-spacing))
-       ((> len 0) 1)
-       (t 0)))
+  (if (>= len indent-bars-spacing) (1+ (/ (1+ len) indent-bars-spacing)) 0))
 
 (defun indent-bars--blank-string (off nbars bar-from &optional width)
   "Return a blank string with bars displayed.



reply via email to

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