GNU bug report logs - #11477
23.1; which-func-cleanup-function should be local

Previous Next

Package: emacs;

Reported by: Jack Duthen <duthen.mac.01 <at> gmail.com>

Date: Tue, 15 May 2012 15:10:02 UTC

Severity: normal

Found in version 23.1

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

Bug is archived. No further changes may be made.

Full log


Message #10 received at 11477-done <at> debbugs.gnu.org (full text, mbox):

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Jack Duthen <duthen.mac.01 <at> gmail.com>
Cc: 11477-done <at> debbugs.gnu.org
Subject: Re: bug#11477: 23.1; which-func-cleanup-function should be local
Date: Tue, 15 May 2012 11:46:22 -0400
> So, as the function name contained in the variable
> "which-func-cleanup-function" can be mode-dependent,
> I think that "which-func-cleanup-function" should be declared
> as buffer local.

locality does not have to be a global property of a variable.
If you only want your cleanup function to be used in a particular
mode/buffer, then set it with (set (make-local-variable '<var>) <val>)
(now available as `setq-local') rather than with `setq'.


        Stefan




This bug report was last modified 13 years and 14 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.