mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-06 06:20:55 -08:00
Fix indent-sexp of #s(...) (Bug#31984)
* lisp/emacs-lisp/lisp-mode.el (indent-sexp): Look for a sexp that ends after the current line. * test/lisp/emacs-lisp/lisp-mode-tests.el (indent-sexp-go): New test.
This commit is contained in:
parent
59e8533286
commit
1b4b96597c
2 changed files with 20 additions and 2 deletions
|
|
@ -1199,8 +1199,14 @@ ENDPOS is encountered."
|
|||
(setq endpos (copy-marker
|
||||
(if endpos endpos
|
||||
;; Get error now if we don't have a complete sexp
|
||||
;; after point.
|
||||
(save-excursion (forward-sexp 1) (point)))))
|
||||
;; after point. We actually look for a sexp which
|
||||
;; ends after the current line so that we properly
|
||||
;; indent things like #s(...). This might not be
|
||||
;; needed if Bug#15998 is fixed.
|
||||
(let ((eol (line-end-position)))
|
||||
(save-excursion (while (and (< (point) eol) (not (eobp)))
|
||||
(forward-sexp 1))
|
||||
(point))))))
|
||||
(save-excursion
|
||||
(while (let ((indent (lisp-indent-calc-next parse-state))
|
||||
(ppss (lisp-indent-state-ppss parse-state)))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue