From: Lars Ingebrigtsen Date: Sat, 25 Jun 2022 12:58:01 +0000 (+0200) Subject: Make `M-q' work on the first line of a multi-line string again X-Git-Tag: emacs-29.0.90~1447^2~1468 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=040c03cae2db361d2e014a52d969a6b0ebc48f1c;p=emacs.git Make `M-q' work on the first line of a multi-line string again * lisp/emacs-lisp/lisp-mode.el (lisp-fill-paragraph): Exclude the quote marks from the region so that filling works (bug#56197). --- diff --git a/lisp/emacs-lisp/lisp-mode.el b/lisp/emacs-lisp/lisp-mode.el index aaec13d1afc..781c80fd5a0 100644 --- a/lisp/emacs-lisp/lisp-mode.el +++ b/lisp/emacs-lisp/lisp-mode.el @@ -1481,8 +1481,8 @@ and initial semicolons." (progn (forward-sexp 1) t)) - (narrow-to-region (ppss-comment-or-string-start ppss) - (point)))) + (narrow-to-region (1+ (ppss-comment-or-string-start ppss)) + (1- (point))))) ;; Move back to where we were. (goto-char start) (fill-paragraph justify)))))))