all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: "Roland Winkler" <winkler@gnu.org>
Cc: Daniel Colascione <dancol@dancol.org>, emacs-devel@gnu.org
Subject: Re: type checking for arbitrary lisp objects
Date: Fri, 11 Apr 2014 16:03:05 -0400	[thread overview]
Message-ID: <jwvtx9zoct5.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <16657.80762.790748.21320@gargle.gargle.HOWL> (Roland Winkler's message of "Fri, 11 Apr 2014 14:22:57 -0500")

>> Why not use cl-deftype?
> ...Interesting! - I guess the main difference to what I have in mind
> is that cl-deftype appears to require some lisp code for FORMS.
> I am thinking about replacing these forms by some more readable
> pattern such as the one I included in my first post.  The function
> bbdb-check-type then compares an arbitrary lisp object against such
> pattern.  I find it more readable and also more flexible to define
> patterns instead of hacking actual code.

AFAIK cl-deftype is specifically there to define those patterns, so you
can later pass them to cl-check-type.


        Stefan



  reply	other threads:[~2014-04-11 20:03 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-11 19:10 type checking for arbitrary lisp objects Roland Winkler
2014-04-11 19:12 ` Daniel Colascione
2014-04-11 19:22   ` Roland Winkler
2014-04-11 20:03     ` Stefan Monnier [this message]
2014-04-12  3:32       ` Roland Winkler
2014-04-12 13:16         ` Stefan Monnier

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=jwvtx9zoct5.fsf-monnier+emacs@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=dancol@dancol.org \
    --cc=emacs-devel@gnu.org \
    --cc=winkler@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.