emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

master d33a6b9069 2/3: Tweak autoloads of defsubsts containing spaces/co


From: Lars Ingebrigtsen
Subject: master d33a6b9069 2/3: Tweak autoloads of defsubsts containing spaces/control chars
Date: Mon, 15 Aug 2022 02:33:14 -0400 (EDT)

branch: master
commit d33a6b9069b6a8272adf720fbb9c1f4a5ec09dd2
Author: Lars Ingebrigtsen <larsi@gnus.org>
Commit: Lars Ingebrigtsen <larsi@gnus.org>

    Tweak autoloads of defsubsts containing spaces/control chars
    
    * lisp/emacs-lisp/loaddefs-gen.el (loaddefs-generate--print-form):
    Escape control chars in bodies so that we don't end up with
    trailing spaces if we're autoloading a defsubst containing
    "\\`[ \t\n\r]*\\'".
---
 lisp/emacs-lisp/loaddefs-gen.el | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/lisp/emacs-lisp/loaddefs-gen.el b/lisp/emacs-lisp/loaddefs-gen.el
index 31e1514193..360b3e4521 100644
--- a/lisp/emacs-lisp/loaddefs-gen.el
+++ b/lisp/emacs-lisp/loaddefs-gen.el
@@ -675,7 +675,9 @@ instead of just updating them with the new/changed 
autoloads."
         (insert "\\\n")))
     (while def
       (insert " ")
-      (prin1 (pop def) (current-buffer) t))
+      (prin1 (pop def) (current-buffer)
+             '(t (escape-newlines . t)
+                 (escape-control-characters . t))))
     (insert ")")))
 
 (defun loaddefs-generate--excluded-files ()



reply via email to

[Prev in Thread] Current Thread [Next in Thread]