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

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

[nongnu] elpa/clojure-ts-mode 4578449356 12/71: indent testing, end_of_d


From: ELPA Syncer
Subject: [nongnu] elpa/clojure-ts-mode 4578449356 12/71: indent testing, end_of_defun bug test (bug is in treesitter)
Date: Fri, 25 Aug 2023 03:59:26 -0400 (EDT)

branch: elpa/clojure-ts-mode
commit 457844935617566767a184d692c49fe0c6f30b81
Author: dannyfreeman <danny@dfreeman.email>
Commit: dannyfreeman <danny@dfreeman.email>

    indent testing, end_of_defun bug test (bug is in treesitter)
    
    Indent doesn't work in all scenarios like indenting in the middle of a
    form with existing line breaks
---
 clojure-ts-mode.el    | 20 ++++++++++----------
 test_end_of_defun.clj |  5 +++++
 2 files changed, 15 insertions(+), 10 deletions(-)

diff --git a/clojure-ts-mode.el b/clojure-ts-mode.el
index 1e9e0e1e19..35a2d052ca 100644
--- a/clojure-ts-mode.el
+++ b/clojure-ts-mode.el
@@ -332,16 +332,16 @@
 
 ;; (defvar clojure-ts-mode--indent-rules
 ;;   '((clojure
-;;      ((parent-is "source")
-;;       parent-bol 0)
-
-;;      ((query ((list_lit :anchor (sym_lit))))
-;;       parent-bol 2)
-
-;;      ((or (parent-is "list_lit")
-;;           (parent-is "vec_lit")
-;;           (parent-is "map_lit"))
-;;       parent-bol 1))))
+;;      ((parent-is "source") parent-bol 0)
+;;      ((parent-is "set_lit") parent-bol 2)
+;;      ((parent-is "vec_lit") parent-bol 1)
+;;      ((parent-is "map_lit") parent-bol 1)
+;;      ;; Lists beginning with a symbol indent 2 spaces (usally a function 
call)
+;;      ((query "(list_lit . (sym_lit) _* @indent)") parent-bol 2)
+;;      ;; All other lists indent 1 space
+;;      ((parent-is "list_lit") parent-bol 1))))
+     ;; Need to deal with deref, tagged literals.
+     
 
 (defvar clojure-ts-mode-map
   (let ((map (make-sparse-keymap)))
diff --git a/test_end_of_defun.clj b/test_end_of_defun.clj
new file mode 100644
index 0000000000..a270163c1e
--- /dev/null
+++ b/test_end_of_defun.clj
@@ -0,0 +1,5 @@
+(:a)
+
+[:b]
+
+{:k a}



reply via email to

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