[Top][All Lists]

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

Re: defcustom: changing from defvar - order of execution

From: Stefan Monnier
Subject: Re: defcustom: changing from defvar - order of execution
Date: Thu, 05 May 2005 23:20:00 -0400
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux)

> The user in setup #2 has never used the library, let's say (and so, does not
> have the setq in .emacs). The user knows nothing about setq and Lisp; he
> just copies the text "(load-library "foo")(foo-fn)", per the library
> comments, to his .emacs. He fires up Emacs, and then uses Customize to set
> and save foovar. This causes (custom-set-variables...) to be added to the
> end of his .emacs - after the load-library and the call to foo-fn.

> The user is then surprised to find that the customization had no effect: in
> subsequent Emacs sessions, load-library does the defcustom, which sets
> foovar to nil; and foo-fn then executes with foovar=nil, returning `t'.

> What am I missing?

That this situation you describe is just a bug in the elisp library.
Most likely in the comment that suggests "(load-library "foo")(foo-fn)",
but it's hard to say without more info.
In any case the scenario you describe doesn't seem to be common.


reply via email to

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