* empty .emacs disables which-func-mode
@ 2005-03-02 12:11 Stephan Stahl
2005-03-03 12:42 ` Stephan Stahl
2005-03-03 20:57 ` Richard Stallman
0 siblings, 2 replies; 3+ messages in thread
From: Stephan Stahl @ 2005-03-02 12:11 UTC (permalink / raw)
Hi.
Using CVS emacs, loading a empty .emacs disables which-func-mode:
emacs -Q
M-x which-func-mode
load empty .emacs
C-x C-f .emacs
now which-fund-mode is disabled.
The reason is that which-func-update catches an error from
imenu--make-index-alist and then disables which-func-mode.
This patch helps but i'm not sure it is the right thing. Can someone
take a look and comment to this?
Thanks,
Stephan
*** which-func.el Wed Mar 2 12:49:37 2005
--- which-func.el.~1.7.~ Tue Jan 11 10:48:10 2005
***************
*** 251,257 ****
(when (and (null name)
(boundp 'imenu--index-alist) (null imenu--index-alist)
(null which-function-imenu-failed))
! (imenu--make-index-alist t)
(unless imenu--index-alist
(make-local-variable 'which-function-imenu-failed)
(setq which-function-imenu-failed t)))
--- 251,257 ----
(when (and (null name)
(boundp 'imenu--index-alist) (null imenu--index-alist)
(null which-function-imenu-failed))
! (imenu--make-index-alist)
(unless imenu--index-alist
(make-local-variable 'which-function-imenu-failed)
(setq which-function-imenu-failed t)))
--
Stephan Stahl
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: empty .emacs disables which-func-mode
2005-03-02 12:11 empty .emacs disables which-func-mode Stephan Stahl
@ 2005-03-03 12:42 ` Stephan Stahl
2005-03-03 20:57 ` Richard Stallman
1 sibling, 0 replies; 3+ messages in thread
From: Stephan Stahl @ 2005-03-03 12:42 UTC (permalink / raw)
Just some more information on this:
which-func-mode gets disabled every time which-func-update runs on a
buffer were imenu--make-index-alist does not find anything and throws
an (error "No items suitable for an index found in this buffer").
This error is caught by which-func-mode which then cancel
which-func-mode.
A easy way to reproduce this is:
emacs -Q
C-h v which-function-mode -> nil
M-x which-func-mode
C-h v which-function-mode -> t
load empty .emacs
C-x C-f /.emacs
/.emacs should not exists and is empty..
C-h v which-function-mode -> nil
Stephan
--
Stephan Stahl
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: empty .emacs disables which-func-mode
2005-03-02 12:11 empty .emacs disables which-func-mode Stephan Stahl
2005-03-03 12:42 ` Stephan Stahl
@ 2005-03-03 20:57 ` Richard Stallman
1 sibling, 0 replies; 3+ messages in thread
From: Richard Stallman @ 2005-03-03 20:57 UTC (permalink / raw)
Cc: emacs-devel
It seems plausiuble to me. Thanks.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2005-03-03 20:57 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-03-02 12:11 empty .emacs disables which-func-mode Stephan Stahl
2005-03-03 12:42 ` Stephan Stahl
2005-03-03 20:57 ` Richard Stallman
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).