From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Hans Aberg Newsgroups: gmane.lisp.guile.devel Subject: Re: summary: lilypond, lambda, and local-eval Date: Thu, 15 Dec 2011 17:52:03 +0100 Message-ID: <9365BFAA-2F16-438E-A6B7-7C2AE4E48B08@telia.com> References: <87r506uodd.fsf@pobox.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v1251.1) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1323967996 27943 80.91.229.12 (15 Dec 2011 16:53:16 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 15 Dec 2011 16:53:16 +0000 (UTC) Cc: guile-devel To: Andy Wingo Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Thu Dec 15 17:53:12 2011 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RbEYR-0005Mb-Qk for guile-devel@m.gmane.org; Thu, 15 Dec 2011 17:53:11 +0100 Original-Received: from localhost ([::1]:39393 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RbEYR-0004bR-Ar for guile-devel@m.gmane.org; Thu, 15 Dec 2011 11:53:11 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:56526) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RbEYO-0004b3-IA for guile-devel@gnu.org; Thu, 15 Dec 2011 11:53:09 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RbEYJ-0003OU-PZ for guile-devel@gnu.org; Thu, 15 Dec 2011 11:53:08 -0500 Original-Received: from smtp-out21.han.skanova.net ([195.67.226.208]:39479) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RbEYJ-0003Nv-C5 for guile-devel@gnu.org; Thu, 15 Dec 2011 11:53:03 -0500 Original-Received: from [10.0.1.2] (217.210.127.13) by smtp-out21.han.skanova.net (8.5.133) (authenticated as u26619196) id 4EC0B93A00CFAB59; Thu, 15 Dec 2011 17:52:04 +0100 In-Reply-To: <87r506uodd.fsf@pobox.com> X-Mailer: Apple Mail (2.1251.1) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 195.67.226.208 X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Original-Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.devel:13117 Archived-At: On 15 Dec 2011, at 11:21, Andy Wingo wrote: > The "delayed evaluation" thread is a bit long and confusing, so I = would > like to try to summarize it. >=20 > Lilypond has a way to embed Lilypond code in Scheme, and Scheme code = in > Lilypond code. The former uses a reader macro, #{#}. The latter uses > specially-marked variables and expressions, specifically, those = preceded > by $ or #. ... > It took some time for everyone to understand the problem. In the end, > there were four workable possibilities. >=20 > 1) Keep using closures. When doing a parser on top of Guile, I noticed one must first build an = unevaluated closure, and only thereafter call the evaluator. Scheme has = some restrictions forcing this, for example, the lambda cannot appear as = a free symbol, though it is possible in Guile using scm_sym_lambda.=20 It might be useful with a variation of scm_eval_string() that only = parses and builds the closure, but not calls the evaluator. Hans