From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Chong Yidong Newsgroups: gmane.emacs.devel Subject: fadr Date: Mon, 22 Jun 2009 11:12:58 -0400 Message-ID: <87zlc0s3np.fsf@stupidchicken.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1245683600 29142 80.91.229.12 (22 Jun 2009 15:13:20 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 22 Jun 2009 15:13:20 +0000 (UTC) Cc: Dmitry Dzhus , emacs-devel@gnu.org To: Nick Roberts Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Jun 22 17:13:17 2009 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1MIlCs-0004zY-Vh for ged-emacs-devel@m.gmane.org; Mon, 22 Jun 2009 17:13:15 +0200 Original-Received: from localhost ([127.0.0.1]:42893 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MIlCr-0000OL-Tj for ged-emacs-devel@m.gmane.org; Mon, 22 Jun 2009 11:13:13 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MIlCl-0000OC-5O for emacs-devel@gnu.org; Mon, 22 Jun 2009 11:13:07 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MIlCg-0000No-Nh for emacs-devel@gnu.org; Mon, 22 Jun 2009 11:13:06 -0400 Original-Received: from [199.232.76.173] (port=55640 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MIlCg-0000Nl-Hh for emacs-devel@gnu.org; Mon, 22 Jun 2009 11:13:02 -0400 Original-Received: from pantheon-po31.its.yale.edu ([130.132.50.82]:32932) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1MIlCg-0001wz-Af for emacs-devel@gnu.org; Mon, 22 Jun 2009 11:13:02 -0400 Original-Received: from furry (dhcp128036014144.central.yale.edu [128.36.14.144]) (authenticated bits=0) by pantheon-po31.its.yale.edu (8.12.11.20060308/8.12.11) with ESMTP id n5MFCwOn024181 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Mon, 22 Jun 2009 11:12:58 -0400 Original-Received: by furry (Postfix, from userid 1000) id 69183C09B; Mon, 22 Jun 2009 11:12:58 -0400 (EDT) X-YaleITSMailFilter: Version 1.2c (attachment(s) not renamed) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.4-2.6 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:111635 Archived-At: 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.