all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Richard Stallman <rms@gnu.org>
To: "Drew Adams" <drew.adams@oracle.com>
Cc: emacs-devel@gnu.org
Subject: Re: custom type `color' is not enforced
Date: Wed, 19 Dec 2007 19:53:47 -0500	[thread overview]
Message-ID: <E1J59fX-0000Jg-SN@fencepost.gnu.org> (raw)
In-Reply-To: <DNEMKBNJBGPAOPIJOOICIEBDECAA.drew.adams@oracle.com>

    The `color' type, in particular, should be easy to test (either the string
    is in the list of color names or it satisfies `#' followed by three groups
    of hex digits).

    Type `regexp' might be more difficult to test, but that too should be
    possible, since we issue invalid-regexp errors for strings that aren't valid
    regexps.

I agree that these changes would be improvements.  However, I don't
think we have any way to test the validity of a regexp without
matching it, and matching it (even against a null string) could
cause an infinite loop.

    I have, for instance, a command `describe-option-of-type' (which I bind to
    `C-h M-o'). It is similar to `describe-variable', but it lets you use
    defcustom types to narrow the set of completion candidates.

I have to say it doesn't sound tremendously useful.

    `C-h M-o color RET TAB' correctly gives all options defined with :type
    `color' (rigid equality test). However, since Emacs currently does not
    distinguish type `color' from type `string' (= this bug),

That statement surprises me.  The two types have different names, and
don't behave the same, so in what sense does Emacs not distinguish
them?

  reply	other threads:[~2007-12-20  0:53 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-02  8:55 custom type `color' is not enforced Drew Adams
2007-12-02  8:59 ` Drew Adams
2007-12-18 23:00   ` Drew Adams
2007-12-20  0:53     ` Richard Stallman [this message]
2007-12-20  1:27       ` Lennart Borgman (gmail)
2007-12-21  3:04         ` Richard Stallman
2007-12-20 19:11       ` Drew Adams
2007-12-20 19:27         ` Drew Adams
2007-12-21  3:59         ` Richard Stallman
2007-12-21  6:47           ` Drew Adams
2007-12-21  3:59         ` Richard Stallman
2007-12-21  6:48           ` Drew Adams
2007-12-21  9:36           ` Lennart Borgman (gmail)
2007-12-21 18:20             ` Drew Adams
2007-12-21 22:03               ` Drew Adams
2007-12-22  6:29             ` Richard Stallman
2007-12-22 20:58               ` Lennart Borgman (gmail)
2007-12-23 10:54                 ` Per Abrahamsen
2007-12-23 12:46                   ` Lennart Borgman (gmail)
2007-12-25 13:52                     ` Per Abrahamsen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=E1J59fX-0000Jg-SN@fencepost.gnu.org \
    --to=rms@gnu.org \
    --cc=drew.adams@oracle.com \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.