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

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

[nongnu] elpa/treesit-fold 0d2b177527 381/417: fix: Update rust line com


From: ELPA Syncer
Subject: [nongnu] elpa/treesit-fold 0d2b177527 381/417: fix: Update rust line comment rule
Date: Mon, 1 Jul 2024 10:03:08 -0400 (EDT)

branch: elpa/treesit-fold
commit 0d2b1775271a14035f6f034080e2be06464aa0b3
Author: JenChieh <jcs090218@gmail.com>
Commit: JenChieh <jcs090218@gmail.com>

    fix: Update rust line comment rule
---
 treesit-fold-parsers.el | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/treesit-fold-parsers.el b/treesit-fold-parsers.el
index 78cbf7805b..ad9dc13aaa 100644
--- a/treesit-fold-parsers.el
+++ b/treesit-fold-parsers.el
@@ -566,8 +566,11 @@
     (match_block            . treesit-fold-range-seq)
     (macro_definition       . (treesit-fold-range-rust-macro 1 -1))
     (block                  . treesit-fold-range-seq)
-    (line_comment           . (lambda (node offset)
-                                (treesit-fold-range-line-comment node offset 
"///")))
+    (line_comment
+     . (lambda (node offset)
+         (treesit-fold-range-line-comment node
+                                          (treesit-fold--cons-add offset '(0 . 
-1))
+                                          "///")))
     (block_comment          . treesit-fold-range-block-comment)))
 
 (defun treesit-fold-parsers-scala ()



reply via email to

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