emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] Changes to emacs/lisp/emacs-lisp/autoload.el,v


From: Glenn Morris
Subject: [Emacs-diffs] Changes to emacs/lisp/emacs-lisp/autoload.el,v
Date: Thu, 05 Jun 2008 02:36:57 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Changes by:     Glenn Morris <gm>       08/06/05 02:36:56

Index: autoload.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/emacs-lisp/autoload.el,v
retrieving revision 1.139
retrieving revision 1.140
diff -u -b -r1.139 -r1.140
--- autoload.el 8 May 2008 03:38:53 -0000       1.139
+++ autoload.el 5 Jun 2008 02:36:56 -0000       1.140
@@ -235,13 +235,13 @@
              (print-escape-nonascii t))
          (print form outbuf)))))))
 
-(defun autoload-ensure-default-file (file)
-  "Make sure that the autoload file FILE exists and if not create it."
-  (unless (file-exists-p file)
+(defun autoload-rubric (file &optional type)
+  "Return a string giving the appropriate autoload rubric for FILE.
+TYPE (default \"autoloads\") is a string stating the type of
+information contained in FILE."
     (let ((basename (file-name-nondirectory file)))
-      (write-region
        (concat ";;; " basename
-              " --- automatically extracted autoloads\n"
+           " --- automatically extracted " (or type "autoloads") "\n"
               ";;\n"
               ";;; Code:\n\n"
               "\n"
@@ -252,8 +252,12 @@
               ";; no-update-autoloads: t\n"
               ";; End:\n"
               ";;; " basename
-              " ends here\n")
-       nil file)))
+           " ends here\n")))
+
+(defun autoload-ensure-default-file (file)
+  "Make sure that the autoload file FILE exists and if not create it."
+  (unless (file-exists-p file)
+    (write-region (autoload-rubric file) nil file))
   file)
 
 (defun autoload-insert-section-header (outbuf autoloads load-name file time)




reply via email to

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