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

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

[nongnu] elpa/swift-mode a489024 344/496: indent-new-comment-line: Inher


From: ELPA Syncer
Subject: [nongnu] elpa/swift-mode a489024 344/496: indent-new-comment-line: Inherit slashes from the previous line
Date: Sun, 29 Aug 2021 11:34:03 -0400 (EDT)

branch: elpa/swift-mode
commit a489024d5058c325e1c758de856d64868d20f3a3
Author: taku0 <mxxouy6x3m_github@tatapa.org>
Commit: taku0 <mxxouy6x3m_github@tatapa.org>

    indent-new-comment-line: Inherit slashes from the previous line
---
 swift-mode-indent.el | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/swift-mode-indent.el b/swift-mode-indent.el
index e7e4951..15a1ec2 100644
--- a/swift-mode-indent.el
+++ b/swift-mode-indent.el
@@ -1455,7 +1455,10 @@ See `indent-new-comment-line' for SOFT."
       (insert-before-markers-and-inherit
        (cond
         (is-single-line-comment
-         "// ")
+         (save-excursion
+           (goto-char comment-beginning-position)
+           (looking-at "/+")
+           (concat (match-string-no-properties 0) space-after-asterisk)))
 
         (comment-multi-line
          (save-excursion



reply via email to

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