From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Dirk Herrmann Newsgroups: gmane.lisp.guile.user Subject: Re: macros, procedure->macro Date: Wed, 3 Jul 2002 22:08:16 +0200 (CEST) Sender: guile-user-admin@gnu.org Message-ID: References: <200207012220.PAA08054@onyx.he.net> NNTP-Posting-Host: localhost.gmane.org Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Trace: main.gmane.org 1025726943 16534 127.0.0.1 (3 Jul 2002 20:09:03 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 3 Jul 2002 20:09:03 +0000 (UTC) Cc: guile-devel@gnu.org, guile-user@gnu.org Return-path: Original-Received: from fencepost.gnu.org ([199.232.76.164]) by main.gmane.org with esmtp (Exim 3.33 #1 (Debian)) id 17PqQw-0004IW-00 for ; Wed, 03 Jul 2002 22:09:02 +0200 Original-Received: from localhost ([127.0.0.1] helo=fencepost.gnu.org) by fencepost.gnu.org with esmtp (Exim 3.34 #1 (Debian)) id 17PqR0-0001P0-00; Wed, 03 Jul 2002 16:09:06 -0400 Original-Received: from sallust.ida.ing.tu-bs.de ([134.169.132.52]) by fencepost.gnu.org with esmtp (Exim 3.34 #1 (Debian)) id 17PqQF-0001MQ-00; Wed, 03 Jul 2002 16:08:19 -0400 Original-Received: from localhost (dirk@localhost) by sallust.ida.ing.tu-bs.de (8.9.3+Sun/8.9.1) with ESMTP id WAA27794; Wed, 3 Jul 2002 22:08:16 +0200 (CEST) Original-To: Gary Houston In-Reply-To: <200207012220.PAA08054@onyx.he.net> Errors-To: guile-user-admin@gnu.org X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.lisp.guile.user:700 X-Report-Spam: http://spam.gmane.org/gmane.lisp.guile.user:700 On 1 Jul 2002, Gary Houston wrote: > > From: Dirk Herrmann > > Date: Mon, 1 Jul 2002 21:56:23 +0200 (CEST) > > > 1) Some macro expert should check that replacing the call to > > procedure->macro in boot-9.scm by a call to procedure->memoizing-macro is > > safe. > > A few others worth checking: > > ./guile-core/oop/goops/save.scm: (procedure->macro > ./guile-core/oop/goops/stklos.scm: (procedure->macro > ./guile-core/oop/goops.scm: (procedure->macro > ./guile-core/oop/goops.scm: (procedure->macro > ./guile-core/oop/goops.scm: (procedure->macro Thanks for pointing these out. I will take a look at them. My current assumption is, that it should be generally safe to replace procedure->macro by procedure->memoizing-macro if the following conditions are met: 1) the macro procedure does not have a stateful behaviour and 2) the transformation of the macro procedure does not depend on the content of the environment argument. If I am not mistaken, these two conditions guarantee, that the transformer will return the same transformed code with every execution. Thus, it could just memoize that code, since it would always be the same anyway. Best regards, Dirk _______________________________________________ Guile-user mailing list Guile-user@gnu.org http://mail.gnu.org/mailman/listinfo/guile-user