From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: dkcombs@panix.com (David Combs) Newsgroups: gmane.emacs.help Subject: Re: Using setq to obtain a symbol from a list, so that I can assign a function to it Date: Sat, 17 May 2008 22:20:53 +0000 (UTC) Organization: Public Access Networks Corp. Message-ID: References: <48505b79-009c-42c9-912f-219a06474731@f24g2000prh.googlegroups.com> <86d4oh9anu.fsf@lifelogs.com> <874p9twxc3.fsf@hubble.informatimago.com> NNTP-Posting-Host: lo.gmane.org X-Trace: ger.gmane.org 1211064080 1187 80.91.229.12 (17 May 2008 22:41:20 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 17 May 2008 22:41:20 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun May 18 00:41:56 2008 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JxV6B-0007TB-BP for geh-help-gnu-emacs@m.gmane.org; Sun, 18 May 2008 00:41:55 +0200 Original-Received: from localhost ([127.0.0.1]:48443 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JxV5R-0000f6-Ow for geh-help-gnu-emacs@m.gmane.org; Sat, 17 May 2008 18:41:09 -0400 Original-Path: news.stanford.edu!headwall.stanford.edu!newshub.sdsu.edu!news-out.readnews.com!transit3.readnews.com!panix!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 47 Original-NNTP-Posting-Host: panix1.panix.com Original-X-Trace: reader2.panix.com 1211062853 19553 166.84.1.1 (17 May 2008 22:20:53 GMT) Original-X-Complaints-To: abuse@panix.com Original-NNTP-Posting-Date: Sat, 17 May 2008 22:20:53 +0000 (UTC) X-Newsreader: trn 4.0-test76 (Apr 2, 2001) Original-Xref: news.stanford.edu gnu.emacs.help:158735 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:54101 Archived-At: In article <874p9twxc3.fsf@hubble.informatimago.com>, Pascal Bourguignon wrote: >Ted Zlatanov writes: > >> On Mon, 21 Apr 2008 19:28:03 -0700 (PDT) srinik001@hotmail.com wrote: >> >> s> So, I am trying to write a tool that will enable me to write specific >> s> XML files by prompting me to enter values. Here is how I am trying to >> s> do it. >> >> You may want to look at the various templating packages available, in >> case one of them does what you want. Check out skeleton.el in >> particular (http://www.emacswiki.org/cgi-bin/wiki/SkeletonMode for some >> examples) since any element of the template can itself be a template. >> That will probably save you a lot of time. >> >> Anytime you find yourself auto-generating functions you should wonder if >> your data structure could be better (sometimes the answer is 'no' :) > >Well, I wouldn't be so categoric. You could start by writting an >"interpreter" of your data, but generating lisp is like implementing >the "compiler", so I don't see much difference. It's so easy to do it >in lisp, that you can go directly to the "compiler". > >-- >__Pascal Bourguignon__ http://www.informatimago.com/ Pascal, If by chance you have (tutorial?) examples of this idea perhaps you could post them here, or point us to a site (one of yours?) that does have such tutorial examples. Of course various text-books contain an example or two, via hairy (*extremely* hairy) macros, but it'd be nice to see a whole bunch in one place, compared, and so on. As I understand it, lisp is *the* language for doing such things -- or has that changed over the years with the introduction (decades ago) of various functional languages? Thanks! David