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

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

[nongnu] elpa/kotlin-mode b689626987 070/162: handle } else { lines for


From: ELPA Syncer
Subject: [nongnu] elpa/kotlin-mode b689626987 070/162: handle } else { lines for indentation
Date: Sat, 29 Jan 2022 08:25:24 -0500 (EST)

branch: elpa/kotlin-mode
commit b689626987aa75d6928f642df894b7b3ea166a63
Author: Gregg Hernandez <gregg@lucidchart.com>
Commit: Gregg Hernandez <gregg@lucidchart.com>

    handle } else { lines for indentation
---
 kotlin-mode.el | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/kotlin-mode.el b/kotlin-mode.el
index 61b35cc8d9..50eeed1006 100644
--- a/kotlin-mode.el
+++ b/kotlin-mode.el
@@ -237,12 +237,12 @@
              (save-excursion
                (while not-indented
                  (forward-line -1)
-                 (cond ((looking-at "^[ \t]*}") ; 3.)
-                        (setq cur-indent (current-indentation))
+                 (cond ((looking-at ".*{[ \t]*$") ; 4.)
+                        (setq cur-indent (+ (current-indentation) 
default-tab-width))
                         (setq not-indented nil))
 
-                       ((looking-at ".*{[ \t]*$") ; 4.)
-                        (setq cur-indent (+ (current-indentation) 
default-tab-width))
+                       ((looking-at "^[ \t]*}") ; 3.)
+                        (setq cur-indent (current-indentation))
                         (setq not-indented nil))
 
                        ((looking-at ".*{.*->[ \t]*$")



reply via email to

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