* 23.0.60; Feature request: eval-defun on defcustom :initialize / :set
@ 2008-04-04 14:03 Reiner Steib
2008-04-04 15:28 ` Sam Steingold
0 siblings, 1 reply; 5+ messages in thread
From: Reiner Steib @ 2008-04-04 14:03 UTC (permalink / raw)
To: emacs-pretest-bug
Hi,
I think `eval-defun' (C-M-x) on a defcustom which has should evaluate
the :initialize or :set function.
Real-life example: Changing the list of regexps in
`smiley-regexp-alist' and doing `C-M-x' has no effect. I modified and
evaluated the defcustom several times until I noticed that I need to
eval `(smiley-update-cache)' as well before my change does anything.
Bye, Reiner.
--
,,,
(o o)
---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: 23.0.60; Feature request: eval-defun on defcustom :initialize / :set
2008-04-04 14:03 23.0.60; Feature request: eval-defun on defcustom :initialize / :set Reiner Steib
@ 2008-04-04 15:28 ` Sam Steingold
2008-04-04 15:33 ` Reiner Steib
0 siblings, 1 reply; 5+ messages in thread
From: Sam Steingold @ 2008-04-04 15:28 UTC (permalink / raw)
To: Reiner Steib; +Cc: emacs-pretest-bug
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Reiner Steib wrote:
|
| I think `eval-defun' (C-M-x) on a defcustom which has should evaluate
| the :initialize or :set function.
|
| Real-life example: Changing the list of regexps in
| `smiley-regexp-alist' and doing `C-M-x' has no effect. I modified and
| evaluated the defcustom several times until I noticed that I need to
| eval `(smiley-update-cache)' as well before my change does anything.
it is not obvious that this is correct.
defcustom is similar to defvar which does not set the the variable if it
is already defined.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFH9kkMPp1Qsf2qnMcRApnPAJ9fX7UhyrWmOBrNJlxlmp01EEBt0wCfbp1R
FB1CV3xsb8dOrQMgI+IPGHY=
=LvsH
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: 23.0.60; Feature request: eval-defun on defcustom :initialize / :set
2008-04-04 15:28 ` Sam Steingold
@ 2008-04-04 15:33 ` Reiner Steib
2008-04-04 18:10 ` Sam Steingold
0 siblings, 1 reply; 5+ messages in thread
From: Reiner Steib @ 2008-04-04 15:33 UTC (permalink / raw)
To: emacs-pretest-bug
On Fri, Apr 04 2008, Sam Steingold wrote:
> Reiner Steib wrote:
> |
> | I think `eval-defun' (C-M-x) on a defcustom which has should evaluate
> | the :initialize or :set function.
[...]
>
> it is not obvious that this is correct.
> defcustom is similar to defvar which does not set the the variable if it
> is already defined.
`eval-defun' _does_ set the variable for both, defvar and defcustom.
Bye, Reiner.
--
,,,
(o o)
---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: 23.0.60; Feature request: eval-defun on defcustom :initialize / :set
2008-04-04 15:33 ` Reiner Steib
@ 2008-04-04 18:10 ` Sam Steingold
2008-04-04 19:07 ` lisp-eval-defun on defvar (was: 23.0.60; Feature request: eval-defun on defcustom :initialize / :set) Reiner Steib
0 siblings, 1 reply; 5+ messages in thread
From: Sam Steingold @ 2008-04-04 18:10 UTC (permalink / raw)
To: emacs-pretest-bug
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Reiner Steib wrote:
| On Fri, Apr 04 2008, Sam Steingold wrote:
|
|> Reiner Steib wrote:
|> |
|> | I think `eval-defun' (C-M-x) on a defcustom which has should evaluate
|> | the :initialize or :set function.
| [...]
|> it is not obvious that this is correct.
|> defcustom is similar to defvar which does not set the the variable if it
|> is already defined.
|
| `eval-defun' _does_ set the variable for both, defvar and defcustom.
cool!
maybe lisp-eval-defun should do the same in inferior lisp?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFH9m8cPp1Qsf2qnMcRAuNuAJ4zZwmLyR1RmUM4erKDj5n4U9EIUQCeIcV1
NET3LOk8qHAitCxKYqaYfzc=
=iImG
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 5+ messages in thread
* lisp-eval-defun on defvar (was: 23.0.60; Feature request: eval-defun on defcustom :initialize / :set)
2008-04-04 18:10 ` Sam Steingold
@ 2008-04-04 19:07 ` Reiner Steib
0 siblings, 0 replies; 5+ messages in thread
From: Reiner Steib @ 2008-04-04 19:07 UTC (permalink / raw)
To: emacs-devel; +Cc: Sam Steingold
On Fri, Apr 04 2008, Sam Steingold wrote:
> Reiner Steib wrote:
> | `eval-defun' _does_ set the variable for both, defvar and defcustom.
>
> cool!
> maybe lisp-eval-defun should do the same in inferior lisp?
I have no opinion on this. But please use a different thread/subject
to discuss this.
Bye, Reiner.
--
,,,
(o o)
---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2008-04-04 19:07 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-04-04 14:03 23.0.60; Feature request: eval-defun on defcustom :initialize / :set Reiner Steib
2008-04-04 15:28 ` Sam Steingold
2008-04-04 15:33 ` Reiner Steib
2008-04-04 18:10 ` Sam Steingold
2008-04-04 19:07 ` lisp-eval-defun on defvar (was: 23.0.60; Feature request: eval-defun on defcustom :initialize / :set) Reiner Steib
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).