File tree 3 files changed +7
-1
lines changed
3 files changed +7
-1
lines changed Original file line number Diff line number Diff line change 24
24
25
25
* [ #588 ] ( https://github.com/clojure-emacs/clojure-mode/pull/588 ) : Fix font-lock for character literals.
26
26
* Stop ` clojure-sort-ns ` from calling ` redisplay ` .
27
+ * [ #608 ] ( https://github.com/clojure-emacs/clojure-mode/issues/608 ) Fix alignment issue involving margin comments at the end of nested forms.
27
28
28
29
### Changes
29
30
Original file line number Diff line number Diff line change @@ -1260,7 +1260,7 @@ BOUND is bounds the whitespace search."
1260
1260
(unwind-protect
1261
1261
(ignore-errors
1262
1262
(clojure-forward-logical-sexp 1 )
1263
- (search-forward-regexp " \\ ([,\s\t ]*\\ )" bound)
1263
+ (search-forward-regexp " \\ ([,\s\t ]*\\ )\\ (;+.* \\ )? " bound)
1264
1264
(pcase (syntax-after (point ))
1265
1265
; ; End-of-line, try again on next line.
1266
1266
(`(12 ) (clojure--search-whitespace-after-next-sexp bound))
Original file line number Diff line number Diff line change 705
705
" #?@(:clj [2]
706
706
:cljs [2])" )
707
707
708
+ (when-aligning-it " should work correctly when margin comments appear after multi-line, non-terminal sexps"
709
+ " (let [:x (+ 2 3
710
+ 3 4) ; comment
711
+ :y (+ 1 2)])" )
712
+
708
713
(it " should handle improperly indented content"
709
714
(let ((content " (let [a-long-name 10\n b 20])" )
710
715
(aligned-content " (let [a-long-name 10\n b 20])" ))
You can’t perform that action at this time.
0 commit comments