all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#13699: 24.2.93; multiple defcustoms for one variable
@ 2013-02-12 19:57 Roland Winkler
  2013-02-12 23:10 ` Glenn Morris
  0 siblings, 1 reply; 4+ messages in thread
From: Roland Winkler @ 2013-02-12 19:57 UTC (permalink / raw)
  To: 13699

start emacs -Q
load the following two files (first bar.el, then baz.el)

cat > bar.el <<EOF
(defcustom foo 'bar
  "This is bar.el.")
EOF

cat > baz.el <<EOF
(defcustom foo 'baz
  "This is baz.el.")
EOF

Expected result:
Either loading baz.el overrides completely loading bar.el,
so that C-h v foo reflects baz.el only.
Or emacs "remembers" bar.el so that C-h foo indicates the fact that
foo was first defined in bar.el and foo kept its value defined there.

Actual result:
C-h v foo says

  foo is a variable defined in `baz.el'.
  Its value is bar
  Original value was baz
  
  Documentation:
  This is baz.el.

The actual value of foo is the original value from bar.el,
but "Original value was baz" denies the fact that this value
stems from bar.el.

I noticed this problem with the variable mail-signature which
sendmail.el initializes with a value of t. But my old version of vm
also initialized it with a value of nil. With sendmail.el being
loaded before vm, I got the value of t, but it took me a little
while to figure out how this value came about.

I suggest that multiple calls of defcustom appearing for the same
variable in different files should be handled consistently so that
it becomes possible to trace back how the value of the variable
came about.


In GNU Emacs 24.2.93.1 (x86_64-unknown-linux-gnu, GTK+ Version 2.12.9)
 of 2013-02-08 on lukas
Windowing system distributor `The X.Org Foundation', version 11.0.10706000
System Description:	Ubuntu 8.04.4 LTS






^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-02-12 23:54 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-12 19:57 bug#13699: 24.2.93; multiple defcustoms for one variable Roland Winkler
2013-02-12 23:10 ` Glenn Morris
2013-02-12 23:23   ` Roland Winkler
2013-02-12 23:54     ` Glenn Morris

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.