diff lisp/emacs-lisp/bytecomp.el @ 70674:13c49a63f416

(byte-compile-warnings-safe-p): New function. (byte-compile-warnings): Fix safe-local-variable property.
author Reiner Steib <Reiner.Steib@gmx.de>
date Tue, 16 May 2006 10:05:09 +0000
parents 63b772bfba93
children c64592812a59 b6689e223e2f a5812696f7bf
line wrap: on
line diff
--- a/lisp/emacs-lisp/bytecomp.el	Tue May 16 10:01:32 2006 +0000
+++ b/lisp/emacs-lisp/bytecomp.el	Tue May 16 10:05:09 2006 +0000
@@ -357,7 +357,20 @@
 		      (const callargs) (const redefine)
 		      (const obsolete) (const noruntime)
 		      (const cl-functions) (const interactive-only))))
-;;;###autoload(put 'byte-compile-warnings 'safe-local-variable 'booleanp)
+(put 'byte-compile-warnings 'safe-local-variable 'byte-compile-warnings-safe-p)
+;;;###autoload
+(defun byte-compile-warnings-safe-p (x)
+  (or (booleanp x)
+      (and (listp x)
+	   (equal (mapcar
+		   (lambda (e)
+		     (when (memq e '(free-vars unresolved
+				     callargs redefine
+				     obsolete noruntime
+				     cl-functions interactive-only))
+		       e))
+		   x)
+		  x))))
 
 (defvar byte-compile-interactive-only-functions
   '(beginning-of-buffer end-of-buffer replace-string replace-regexp