help-gnu-emacs
[Top][All Lists]
Advanced

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

[BUG] in defcustom docstring (was Re: Whats wrong with this defcustom?)


From: Thorsten Jolitz
Subject: [BUG] in defcustom docstring (was Re: Whats wrong with this defcustom?)
Date: Tue, 29 Jul 2014 00:11:05 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

Tassilo Horn <tsdh@gnu.org> writes:

> Thorsten Jolitz <tjolitz@gmail.com> writes:
>
> Hi Thorsten,
>
>> I'm probably overlooking the obvious, but what is wrong with this
>> defcustom:
>>
>> ,----
>> | (defcustom org-x-style 'notes
>> |   "Possible styles for diagrams."
>> |   :group 'org-x
>> |   :type '(choice (const :tag "Sync-bars" 'sync-bars)
>> |             (const :tag "Partitions" 'partitions)
>> |             (const :tag "Notes" 'notes)))
>> `----
>
> ,----[ C-h f defcustom RET ]
> | defcustom is a Lisp macro in `custom.el'.
> | 
> | (defcustom SYMBOL STANDARD DOC &rest ARGS)
> | 
> | Declare SYMBOL as a customizable variable.
> | SYMBOL is the variable name; it should not be quoted.
> | STANDARD is an expression specifying the variable's standard
> | value.  It should not be quoted.
> |         ^^^^^^^^^^^^^^^^^^^^^^^
> `----

If I don't quote STANDARD I get a load-error, so either the docstring is
lying or I'm already confused about this whole issue ...

Recipe:

1. emacs -Q
2. C-x C-f ~/junk/test.el ; new empty test file
3. insert '(defcustom foo bar "loo")'
4. C-x C-s
5. M-x eval-buffer

-> 
,----
| custom-initialize-reset:
|   Symbol's value as variable is void: bar
`----

-- 
cheers,
Thorsten




reply via email to

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