branch: externals/auctex
commit 01b30cb491fc2f88ba0d24cec3a87c6b23beff0f
Author: Tassilo Horn <t...@gnu.org>
Commit: Tassilo Horn <t...@gnu.org>

    Fix filling of code-and-comment lins where code ended in \% (bug#48937)
    
    * latex.el (LaTeX-fill-region-as-paragraph): Fix filling of
    code-and-comment lins where code ended in \% (bug#48937).
---
 latex.el | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/latex.el b/latex.el
index 5204ff4..a8db1a9 100644
--- a/latex.el
+++ b/latex.el
@@ -3814,8 +3814,8 @@ performed in that case."
           (if (re-search-forward
                (concat "\\("
                        ;; Code comments.
-                       "[^ \r\n%\\]\\([ \t]\\|\\\\\\\\\\)*"
-                       TeX-comment-start-regexp
+                       "\\([^ \r\n%\\]\\|\\\\%\\)\\([ \t]\\|\\\\\\\\\\)*"
+                       "[^\r\n\\]" TeX-comment-start-regexp
                        "\\|"
                        ;; Lines ending with `\par'.
                        "\\(\\=\\|[^" TeX-esc "\n]\\)\\("

Reply via email to