]> code.delx.au - gnu-emacs/blobdiff - lisp/emacs-lisp/autoload.el
Merge from trunk; up to 2013-02-18T01:30:27Z!monnier@iro.umontreal.ca.
[gnu-emacs] / lisp / emacs-lisp / autoload.el
index 3fc185dda25b76dfbaea426bda590f99477da197..edaecd7ff1995843bc757f9de75bda8775f40d3d 100644 (file)
@@ -1,6 +1,6 @@
 ;; autoload.el --- maintain autoloads in loaddefs.el  -*- lexical-binding: t -*-
 
-;; Copyright (C) 1991-1997, 2001-201 Free Software Foundation, Inc.
+;; Copyright (C) 1991-1997, 2001-2013 Free Software Foundation, Inc.
 
 ;; Author: Roland McGrath <roland@gnu.org>
 ;; Keywords: maint
@@ -153,7 +153,7 @@ expression, in which case we want to handle forms differently."
                   easy-mmode-define-minor-mode define-minor-mode
                   cl-defun defun* cl-defmacro defmacro*
                    define-overloadable-function))
-      (let* ((macrop (memq car '(defmacro defmacro*)))
+      (let* ((macrop (memq car '(defmacro cl-defmacro defmacro*)))
             (name (nth 1 form))
             (args (pcase car
                      ((or `defun `defmacro
@@ -228,7 +228,8 @@ expression, in which case we want to handle forms differently."
 (defun autoload-find-generated-file ()
   "Visit the autoload file for the current buffer, and return its buffer.
 If a buffer is visiting the desired autoload file, return it."
-  (let ((enable-local-variables :safe))
+  (let ((enable-local-variables :safe)
+       (enable-local-eval nil))
     ;; We used to use `raw-text' to read this file, but this causes
     ;; problems when the file contains non-ASCII characters.
     (find-file-noselect
@@ -382,7 +383,8 @@ which lists the file name and which functions are in it, etc."
     (emacs-lisp-mode)
     (setq default-directory (file-name-directory file))
     (insert-file-contents file nil)
-    (let ((enable-local-variables :safe))
+    (let ((enable-local-variables :safe)
+         (enable-local-eval nil))
       (hack-local-variables))
     (current-buffer)))