[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: |
Sat, 21 Sep 2002 10:57:38 +0900 (JST) |
User-agent: |
SEMI/1.14.3 (Ushinoya) FLIM/1.14.2 (Yagi-Nishiguchi) APEL/10.2 Emacs/21.1.30 (sparc-sun-solaris2.6) MULE/5.0 (SAKAKI) |
References: <address@hidden> <address@hidden> <address@hidden> <address@hidden>
--text follows this line--
In article <address@hidden>, "Stefan Monnier" <monnier+gnu/address@hidden>
writes:
>> But, it seems that, with this, if :init-value is t, the
>> function to do various settings to make the mode work is
>> never called.
> Do you mean that you'd rather see
> ,(if globalp
> `(if (and load-file-name (not (equal ,mode ,init-value)))
> (eval-after-load load-file-name
> '(,mode (if ,mode 1 -1)))))
No.
> I'm not sure it's worth the trouble. The reason for this little piece
> of code is so as to call (foo-mode 1) when people do (setq foo-mode t)
> in their .emacs and then load foo-mode.el.
> But people shouldn't use (setq foo-mode t), they should use (foo-mode 1)
> instead anyway.
> So I'd rather use that code less often rather than more often.
What I want is to make this work well at bootstrapping time
because now ucs-tables.el is preloaded.
(define-minor-mode unify-8859-on-encoding-mode
"..."
:group 'mule
:global t
:init-value t
(if unify-8859-on-encoding-mode
(ucs-unify-8859 t)
(ucs-fragment-8859 t)))
When use-tables.el is loaded and this code run, it must run
(if ...) after setting the variable
unify-8859-on-encoding-mode to t. Otherwise, the value of
unify-8859-on-encoding-mode doesn't synchronize with the
acutual status of the mode.
Before your change, define-minor-mode tried to run (if ...)
part through eval-after-load. But, eval-after-load doesn't
work at bootstrapping time as I wrote before.
After your change, define-minor-mode never run (if ...),
which is worse.
Or, am I misunderstanding the functionality of
define-minor-mode?
---
Ken'ichi HANDA
address@hidden
- problem of define-minor-mode while bootstrapping, Kenichi Handa, 2002/09/19
- Re: problem of define-minor-mode while bootstrapping, Stefan Monnier, 2002/09/19
- Re: problem of define-minor-mode while bootstrapping, Kenichi Handa, 2002/09/19
- Re: problem of define-minor-mode while bootstrapping, Stefan Monnier, 2002/09/20
- Re: problem of define-minor-mode while bootstrapping,
Kenichi Handa <=
- Re: problem of define-minor-mode while bootstrapping, Stefan Monnier, 2002/09/22
- Re: problem of define-minor-mode while bootstrapping, Kenichi Handa, 2002/09/22
- Re: problem of define-minor-mode while bootstrapping, Stefan Monnier, 2002/09/23
- Re: problem of define-minor-mode while bootstrapping, Kenichi Handa, 2002/09/23
- Re: problem of define-minor-mode while bootstrapping, Stefan Monnier, 2002/09/24
- Re: problem of define-minor-mode while bootstrapping, Kenichi Handa, 2002/09/24
- Re: problem of define-minor-mode while bootstrapping, Miles Bader, 2002/09/20
- Re: problem of define-minor-mode while bootstrapping, Richard Stallman, 2002/09/22
- Re: problem of define-minor-mode while bootstrapping, Dave Love, 2002/09/25
- Re: problem of define-minor-mode while bootstrapping, Richard Stallman, 2002/09/26