GNU bug report logs -
#9820
24.0.90; Behaviour of add-file-local-variable
Previous Next
Reported by: Jambunathan K <kjambunathan <at> gmail.com>
Date: Fri, 21 Oct 2011 05:14:02 UTC
Severity: wishlist
Found in version 24.0.90
Fixed in version 24.3.50
Done: Juri Linkov <juri <at> jurta.org>
Bug is archived. No further changes may be made.
Full log
Message #11 received at 9820 <at> debbugs.gnu.org (full text, mbox):
> === modified file 'lisp/files-x.el'
> --- lisp/files-x.el 2011-04-19 13:44:55 +0000
> +++ lisp/files-x.el 2011-10-21 14:04:22 +0000
> @@ -214,7 +214,11 @@ (defun add-file-local-variable (variable
> (interactive
> (let ((variable (read-file-local-variable "Add file-local variable")))
> (list variable (read-file-local-variable-value variable))))
> - (modify-file-local-variable variable value 'add-or-replace))
> + (modify-file-local-variable variable value 'add-or-replace)
> + (when (and (called-interactively-p 'interactive)
> + (symbolp variable) (boundp variable)
> + (not (equal (symbol-value variable) value)))
> + (message "Revisit file to make this change take effect")))
Please pass use an optional `interactive' arg instead
of called-interactively-p.
You might even want to pass that arg down to modify-file-local-variable
so as to avoid duplicating the test and message.
Stefan
This bug report was last modified 12 years and 61 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.