emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: /etc/TODO: define-minor-mode & minor-mode-list


From: Juanma Barranquero
Subject: Re: /etc/TODO: define-minor-mode & minor-mode-list
Date: Wed, 1 Feb 2012 04:39:19 +0100

On Wed, Feb 1, 2012 at 03:46, William Stevenson <address@hidden> wrote:

> Sorry, I didn't explain clearly. I found that abbrev-mode was the _only_
> mode that could be removed from the definition and still end up in the
> list. And my confusion arose from my inability to see what caused this
> when all 5 of these modes are defined using define-minor-mode.

These modes are all auto-loaded, but if you look at the definition of
define-minor-mode, you'll see that the part that invokes
add-minor-mode (and so, sets minor-mode-list) is not autoloaded (it's
after :autoload-end). So these modes do not enter into minor-mode-list
until they are run. I haven't checked, but I suspect that abbrev-mode
is run at some point during initialization and so it does enter the
list.

    Juanma



reply via email to

[Prev in Thread] Current Thread [Next in Thread]