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

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

[nongnu] elpa/nix-mode 6eaf2a97d2 069/500: Fixup hanging indent.


From: ELPA Syncer
Subject: [nongnu] elpa/nix-mode 6eaf2a97d2 069/500: Fixup hanging indent.
Date: Sat, 29 Jan 2022 08:26:37 -0500 (EST)

branch: elpa/nix-mode
commit 6eaf2a97d289ce69e15940a8d0bdc64e1d95a0ba
Author: Matthew Bauer <mjbauer95@gmail.com>
Commit: Matthew Bauer <mjbauer95@gmail.com>

    Fixup hanging indent.
---
 nix-mode.el | 34 +++++++++++++++-------------------
 1 file changed, 15 insertions(+), 19 deletions(-)

diff --git a/nix-mode.el b/nix-mode.el
index 99e0f9f0de..53b00b5630 100644
--- a/nix-mode.el
+++ b/nix-mode.el
@@ -229,25 +229,21 @@ If a close brace `}' ends an antiquote, the next 
character begins a string."
   (save-excursion
     (beginning-of-line)
     (skip-chars-forward "[:space:]")
-    (unless (or
-            (looking-at "}")
-            (looking-at ")")
-            (looking-at "{"))
-
-      (forward-line -1)
-      (end-of-line)
-      (skip-chars-backward "\n[:space:]")
-
-      ;; skip through any comments in the way
-      (while (nth 4 (syntax-ppss))
-       (goto-char (nth 8 (syntax-ppss)))
-       (skip-chars-backward "\n[:space:]"))
-
-      (or
-       (looking-back "=" 1)
-       (looking-back "+" 1)
-       ;; (looking-back ":" 1)
-       (looking-back "//" 1)))))
+
+    (forward-line -1)
+    (end-of-line)
+    (skip-chars-backward "\n[:space:]")
+
+    ;; skip through any comments in the way
+    (while (nth 4 (syntax-ppss))
+      (goto-char (nth 8 (syntax-ppss)))
+      (skip-chars-backward "\n[:space:]"))
+
+    (or
+     (looking-back "=" 1)
+     (looking-back "+" 1)
+     ;; (looking-back ":" 1)
+     (looking-back "//" 1))))
 
 (defun nix-indent-level ()
   "Get current indent level."



reply via email to

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