[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: problem of define-minor-mode while bootstrapping
From: |
Kenichi Handa |
Subject: |
Re: problem of define-minor-mode while bootstrapping |
Date: |
Fri, 18 Oct 2002 17:38:46 +0900 (JST) |
In article <address@hidden>, Richard Stallman <address@hidden> writes:
> I looked at RC and found this code:
> ;; If the mode is global, call the function according to the default.
> ,(if globalp
> `(if (and load-file-name ,mode)
> (eval-after-load load-file-name '(,mode 1)))))))
> As far as I can tell, the (null init-value) was never there.
Oops, perhaps the code I quoted was from easy-mmode.el of
the version 1.42 of HEAD. Sorry for the confusion.
> Should I add it?
No, I don't think so.
> Anyway, I think the bug you found can be fixed this way:
> ;; If the mode is global, call the function according to the default.
> ,(if globalp
> `(if (and load-file-name ,mode
> (not purify-flag))
> (eval-after-load load-file-name '(,mode 1)))))))
> Does that fix work?
With this change, at least, setting :init-value to t doesn't
cause a trouble at bootstrapping time.
We still should have the code to turn that minor mode on
explicitely as below:
(define-minor-mode XXX-mode "..." :init-value t ...)
(XXX-mode 1)
But, I think that is ok because that is necessary only for a
preloaded file.
---
Ken'ichi HANDA
address@hidden