changeset 70283:fe86bf681435

* help-fns.el (describe-variable): Add info about safe local variables. * custom.texi (Examining): Update C-h v output example.
author Dan Nicolaescu <dann@ics.uci.edu>
date Sat, 29 Apr 2006 21:18:05 +0000
parents f7ef1c0da4f9
children 1a11061f92fa
files lisp/ChangeLog lisp/help-fns.el man/ChangeLog man/custom.texi
diffstat 4 files changed, 17 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Sat Apr 29 20:15:48 2006 +0000
+++ b/lisp/ChangeLog	Sat Apr 29 21:18:05 2006 +0000
@@ -1,3 +1,7 @@
+2006-04-29  Dan Nicolaescu  <dann@ics.uci.edu>
+
+	* help-fns.el (describe-variable): Add info about safe local variables.
+
 2006-04-29  Richard Stallman  <rms@gnu.org>
 
 	* net/tramp.el (tramp-file-name-handler-alist): Delete
--- a/lisp/help-fns.el	Sat Apr 29 20:15:48 2006 +0000
+++ b/lisp/help-fns.el	Sat Apr 29 21:18:05 2006 +0000
@@ -630,6 +630,7 @@
                              (indirect-variable variable)
                            (error variable)))
                    (obsolete (get variable 'byte-obsolete-variable))
+		   (safe-var (get variable 'safe-local-variable))
                    (doc (or (documentation-property variable 'variable-documentation)
                             (documentation-property alias 'variable-documentation))))
               (unless (eq alias variable)
@@ -641,6 +642,11 @@
                 (princ (if (stringp (car obsolete)) (car obsolete)
                          (format "use `%s' instead." (car obsolete))))
                 (terpri))
+	      (when safe-var 
+		(princ "This variable is safe to use as a file local variable")
+		(princ (format " only if its value\nsatisfies the predicate `%s'.\n"
+			       safe-var))
+		(terpri))
 	      (princ "Documentation:\n")
               (princ (or doc "Not documented as a variable.")))
 	    ;; Make a link to customize if this variable can be customized.
--- a/man/ChangeLog	Sat Apr 29 20:15:48 2006 +0000
+++ b/man/ChangeLog	Sat Apr 29 21:18:05 2006 +0000
@@ -1,3 +1,7 @@
+2006-04-29  Dan Nicolaescu  <dann@ics.uci.edu>
+
+	* custom.texi (Examining): Update C-h v output example.
+
 2006-04-29  Kim F. Storm  <storm@cua.dk>
 
 	* building.texi (Grep Searching): Add lgrep and rgrep.
--- a/man/custom.texi	Sat Apr 29 20:15:48 2006 +0000
+++ b/man/custom.texi	Sat Apr 29 21:18:05 2006 +0000
@@ -822,6 +822,9 @@
 Local in buffer custom.texi; global value is 70
 Automatically becomes buffer-local when set in any fashion.
 
+This variable is safe to use as a file local variable only if its value
+satisfies the predicate `integerp'.
+
 Documentation:
 *Column beyond which automatic line-wrapping should happen.
 Interactively, you can set the buffer local value using C-x f.