GNU bug report logs -
#16271
warn about quoted const's in defcustom
Previous Next
Reported by: Glenn Morris <rgm <at> gnu.org>
Date: Sat, 28 Dec 2013 02:21:01 UTC
Severity: wishlist
Tags: moreinfo
Fixed in version 29.1
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
Message #11 received at 16271 <at> debbugs.gnu.org (full text, mbox):
> > The argument of a `const' (or `other') inside a defcustom type should
> > (almost always) not be quoted. Yet people keep doing it.
> > It would be nice if there was some way to warn about this.
>
> Yes, that would be nice, so I've now implemented it. However, there's
> one false positive:
>
> (defcustom erc-button-alist
> '(('nicknames 0 erc-button-buttonize-nicks erc-nick-popup 0)
> ...
> (choice :tag "Matches"
> regexp
> (variable :tag "Variable containing regexp")
> ;; FIXME It really does mean 'nicknames
> ;; rather than just nicknames.
> (const :tag "Nicknames" 'nicknames))
>
> And this really means 'nicknames. Anybody got any suggestions how to
> work around that?
Don't work around it.
Don't try to warn not to quote.
In (elisp) `Composite Types', (1) mention that
you typically do not want to quote, and (2)
show an example of the exception, with a quote,
saying what the behavior is in that case.
Warnings are not appropriate here, and will
likely confuse. Making the case clear in the
doc is helpful.
This bug report was last modified 3 years and 15 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.