Use a named function for 'safe-local-variable
This improves the help screen for `version-control' (Bug#25431). * lisp/files.el (version-control-safe-local-p): New function. (version-control): Use it.
This commit is contained in:
parent
ef44346782
commit
1531c3c9f2
1 changed files with 6 additions and 1 deletions
|
@ -279,8 +279,13 @@ The value `never' means do not make them."
|
|||
(const :tag "If existing" nil)
|
||||
(other :tag "Always" t))
|
||||
:group 'backup)
|
||||
|
||||
(defun version-control-safe-local-p (x)
|
||||
"Return whether X is safe as local value for `version-control'."
|
||||
(or (booleanp x) (equal x 'never)))
|
||||
|
||||
(put 'version-control 'safe-local-variable
|
||||
(lambda (x) (or (booleanp x) (equal x 'never))))
|
||||
#'version-control-safe-local-p)
|
||||
|
||||
(defcustom dired-kept-versions 2
|
||||
"When cleaning directory, number of versions to keep."
|
||||
|
|
Loading…
Add table
Reference in a new issue