GNU bug report logs - #9820
24.0.90; Behaviour of add-file-local-variable

Previous Next

Package: emacs;

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


View this message in rfc822 format

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Juri Linkov <juri <at> jurta.org>
Cc: Jambunathan K <kjambunathan <at> gmail.com>, 9820 <at> debbugs.gnu.org
Subject: bug#9820: 24.0.90; Behaviour of add-file-local-variable
Date: Sat, 15 Jun 2013 20:50:15 -0400
> -	  (insert (format "%s%S: %S%s\n" prefix variable value suffix)))))))
> +	  (insert (format "%s%S: %S%s\n" prefix variable value suffix)))
> +
> +	(when (and interactive
> +		   (not (and (symbolp variable)
> +			     (boundp variable)
> +			     (equal (symbol-value variable) value))))
> +	  (message "%s" (substitute-command-keys
> +			 "For this change to take effect revisit file using \\[revert-buffer]"))))))))

Looks good, thanks.

> -	  (unless (eq (char-after) ?\s) (insert " "))))))))
> +	  (unless (eq (char-after) ?\s) (insert " "))))))
> +
> +    (when (and interactive
> +	       (not (and (symbolp variable)
> +			 (boundp variable)
> +			 (equal (symbol-value variable) value))))
> +      (message "%s" (substitute-command-keys
> +		     "For this change to take effect revisit file using \\[revert-buffer]")))))

But please eliminate this code duplication.


        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.