unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Chong Yidong <cyd@stupidchicken.com>
To: Nick Roberts  <nickrob@snap.net.nz>
Cc: Dmitry Dzhus <dima@sphinx.net.ru>, emacs-devel@gnu.org
Subject: fadr
Date: Mon, 22 Jun 2009 11:12:58 -0400	[thread overview]
Message-ID: <87zlc0s3np.fsf@stupidchicken.com> (raw)

Hi Nick,

I noticed that you checked in fadr.el into lisp/.  After looking through
the file, I have significant reservations:

 * A Lisp utility library like this should go into lisp/emacs-lisp/
   instead of the main lisp/ directory.

 * It's completely unclear what "fadr" stands for.  If we keep this
   file, we must rename it to something less cryptic.

 * More fundamentally, I think the way this library works is misguided.
   The example given in the commentary says:

     (setq basket '((apples . (((color . green) (taste . delicious))
                           ((color . red) (taste . disgusting))))))

     Its contents may be accessed using `fadr-member':
     (fadr-member basket ".apples[1].color")
     red

   If I understand correctly, this smacks of trying to shoehorn C
   structure-addressing habits into Emacs Lisp.  Passing a "black-box"
   string argument like ".apples[1].color" is ugly and un-Lispy.

Unless there is some overriding reason, I think the GDB-MI project
should drop the fadr dependency.  If you need a way to interface easily
with nested structures, I suggest using Common Lisp structures, i.e. the
`defstruct' macro which has been in cl-macs.el for a long time.




             reply	other threads:[~2009-06-22 15:12 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-22 15:12 Chong Yidong [this message]
2009-06-22 16:14 ` fadr Thien-Thi Nguyen
2009-06-22 19:56   ` fadr Dmitry Dzhus
2009-06-23  9:14     ` fadr Thien-Thi Nguyen
2009-06-22 16:27 ` fadr Dmitry Dzhus
2009-06-22 16:39   ` fadr Chong Yidong
2009-06-22 18:24   ` fadr Glenn Morris
2009-06-22 21:57     ` fadr Dmitry Dzhus
2009-06-24 21:33       ` fadr Stefan Monnier
2009-06-23  5:54     ` fadr Nick Roberts
2009-06-22 21:38 ` fadr Dmitry Dzhus
2009-06-23  5:47 ` fadr Nick Roberts

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=87zlc0s3np.fsf@stupidchicken.com \
    --to=cyd@stupidchicken.com \
    --cc=dima@sphinx.net.ru \
    --cc=emacs-devel@gnu.org \
    --cc=nickrob@snap.net.nz \
    /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 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).