Mercurial > emacs
changeset 52987:ac21698ba968
(add-hook): Fix last change.
author | Stefan Monnier <monnier@iro.umontreal.ca> |
---|---|
date | Mon, 03 Nov 2003 14:44:48 +0000 |
parents | 5feae36d70a9 |
children | f2e9f66ff625 |
files | lisp/subr.el |
diffstat | 1 files changed, 1 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/subr.el Mon Nov 03 06:23:11 2003 +0000 +++ b/lisp/subr.el Mon Nov 03 14:44:48 2003 +0000 @@ -856,9 +856,7 @@ (set (make-local-variable hook) (list t))) ;; Detect the case where make-local-variable was used on a hook ;; and do what we used to do. - (when (and (local-variable-p hook) - (not (and (consp (symbol-value hook)) - (memq t (symbol-value hook))))) + (unless (and (consp (symbol-value hook)) (memq t (symbol-value hook))) (setq local t))) (let ((hook-value (if local (symbol-value hook) (default-value hook)))) ;; If the hook value is a single function, turn it into a list.