Closed stig closed 2 months ago
Hello thanks for opening a ticket.
I am unable to reproduce this. Can you try to see if this bad fill-paragraph
behavior still occurs when you use clojure-ts-mode when running Emacs with emacs -Q
? When I run with emacs -Q
on linux with emacs 29.4 I get the expected behavior.
I did some binary searching, and found that this patch to my config fixes the issue:
@@ -385,7 +385,7 @@
(add-hook 'message-mode-hook #'orgalist-mode)
(add-hook 'git-commit-setup-hook #'orgalist-mode)
(add-hook 'markdown-mode-hook #'orgalist-mode)
-(add-hook 'prog-mode-hook #'orgalist-mode)
+;; (add-hook 'prog-mode-hook #'orgalist-mode)
(require 'subword)
(add-hook 'prog-mode-hook #'subword-mode)
I can live with that :-)
Use the template below when reporting bugs. Please, make sure that you're running the latest stable clojure-ts-mode and that the problem you're reporting hasn't been reported (and potentially fixed) already.
Please, remove all of the placeholder text (the one in italics) in your final report!
Expected behavior
Clojure TS Mode should support comments being filled (using
M-x fill-paragraph
or similar) without disturbing surrounding code, like regular Clojure Mode.Actual behavior
In Clojure TS Mode
fill-paragraph
will happily mangle surrounding code when attempting to dofill-paragraph
on a comment.Steps to reproduce the problem
This is extremely important! Providing us with a reliable way to reproduce a problem will expedite its solution.
Place cursor somewhere in the comment of this example, and invoke
M-x fill-paragraph
:This produces the following token salad:
Instead I would expect to see this instead (and regular Clojure Mode does this)
Environment & Version information
clojure-ts-mode version
tree-sitter-clojure grammar version
v0.0.12
Emacs version
Operating system
MacOS