changeset 22003:ea83fc4c4f77

(generate-file-autoloads): Handle progn forms generated by make-autoload: print just the first subform with print-escape-newlines.
author Richard M. Stallman <rms@gnu.org>
date Sat, 09 May 1998 07:02:50 +0000
parents c40d3d44e6fd
children 79a3c4eba19f
files lisp/emacs-lisp/autoload.el
diffstat 1 files changed, 11 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/emacs-lisp/autoload.el	Sat May 09 06:40:53 1998 +0000
+++ b/lisp/emacs-lisp/autoload.el	Sat May 09 07:02:50 1998 +0000
@@ -220,7 +220,10 @@
 			;; Read the next form and make an autoload.
 			(let* ((form (prog1 (read (current-buffer))
 				       (or (bolp) (forward-line 1))))
-			       (autoload (make-autoload form load-name))
+			       (autoload-1 (make-autoload form load-name))
+			       (autoload (if (eq (car autoload-1) 'progn)
+					     (cadr autoload-1)
+					   autoload-1))
 			       (doc-string-elt (get (car-safe form)
 						    'doc-string-elt)))
 			  (if autoload
@@ -267,7 +270,13 @@
 					   outbuf))
 				  (terpri outbuf)))
 			    (let ((print-escape-newlines t))
-			      (print autoload outbuf))))
+			      (print autoload outbuf)))
+			  (if (eq (car autoload-1) 'progn)
+			      ;; Print the rest of the form
+			      (let ((print-escape-newlines t))
+				(mapcar (function (lambda (elt)
+						    (print elt outbuf)))
+					(cddr autoload-1)))))
 			  ;; Copy the rest of the line to the output.
 		      (princ (buffer-substring
 			      (progn