From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andreas Rottmann Newsgroups: gmane.lisp.guile.devel Subject: [PATCH] ice-9 receive without defmacro Date: Sat, 19 Jun 2010 14:10:34 +0200 Message-ID: <87iq5fussl.fsf@delenn.lan> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: dough.gmane.org 1276949464 21227 80.91.229.12 (19 Jun 2010 12:11:04 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sat, 19 Jun 2010 12:11:04 +0000 (UTC) To: Guile Development Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Sat Jun 19 14:10:59 2010 connect(): No such file or directory Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1OPwsw-0005Kt-Lh for guile-devel@m.gmane.org; Sat, 19 Jun 2010 14:10:55 +0200 Original-Received: from localhost ([127.0.0.1]:36006 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OPwsw-0003fC-1N for guile-devel@m.gmane.org; Sat, 19 Jun 2010 08:10:54 -0400 Original-Received: from [140.186.70.92] (port=39493 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OPwsj-0003cK-UX for guile-devel@gnu.org; Sat, 19 Jun 2010 08:10:44 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OPwsi-00014u-R7 for guile-devel@gnu.org; Sat, 19 Jun 2010 08:10:41 -0400 Original-Received: from mail.gmx.net ([213.165.64.20]:59346) by eggs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1OPwsi-00014G-G4 for guile-devel@gnu.org; Sat, 19 Jun 2010 08:10:40 -0400 Original-Received: (qmail invoked by alias); 19 Jun 2010 12:10:39 -0000 Original-Received: from 83-215-154-5.hage.dyn.salzburg-online.at (EHLO nathot.lan) [83.215.154.5] by mail.gmx.net (mp062) with SMTP; 19 Jun 2010 14:10:39 +0200 X-Authenticated: #3102804 X-Provags-ID: V01U2FsdGVkX1+Sg2I76oGSzzwama6Nv0S6pFZSdrOELIy8pykwi1 QWVdDyK7rFSYD5 Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by nathot.lan (Postfix) with ESMTP id EED153A62F for ; Sat, 19 Jun 2010 14:10:37 +0200 (CEST) Original-Received: from nathot.lan ([127.0.0.1]) by localhost (nathot.lan [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id wGpuRwpzDmQa for ; Sat, 19 Jun 2010 14:10:34 +0200 (CEST) Original-Received: from delenn.lan (delenn.lan [192.168.3.11]) by nathot.lan (Postfix) with ESMTP id 3C8E53A62E for ; Sat, 19 Jun 2010 14:10:34 +0200 (CEST) Original-Received: by delenn.lan (Postfix, from userid 1000) id 3539D74DC4; Sat, 19 Jun 2010 14:10:34 +0200 (CEST) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) X-Y-GMX-Trusted: 0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.devel:10514 Archived-At: --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=receive-without-defmacro.diff From: Andreas Rottmann Subject: ice-9 receive without define-macro * module/ice-9/receive.scm: Replace define-macro usage with syntax-rules. --- module/ice-9/receive.scm | 10 ++++++---- 1 files changed, 6 insertions(+), 4 deletions(-) diff --git a/module/ice-9/receive.scm b/module/ice-9/receive.scm index d550c6f..f4f4d81 100644 --- a/module/ice-9/receive.scm +++ b/module/ice-9/receive.scm @@ -1,6 +1,6 @@ ;;;; SRFI-8 -;;; Copyright (C) 2000, 2001, 2004, 2006 Free Software Foundation, Inc. +;;; Copyright (C) 2000, 2001, 2004, 2006, 2010 Free Software Foundation, Inc. ;;; ;;;; This library is free software; you can redistribute it and/or ;;;; modify it under the terms of the GNU Lesser General Public @@ -21,8 +21,10 @@ :no-backtrace ) -(define-macro (receive vars vals . body) - `(call-with-values (lambda () ,vals) - (lambda ,vars ,@body))) +(define-syntax receive + (syntax-rules () + ((receive vars vals . body) + (call-with-values (lambda () vals) + (lambda vars . body))))) (cond-expand-provide (current-module) '(srfi-8)) -- tg: (c399333..) t/receive-without-defmacro (depends on: master) --=-=-= Regards, -- Andreas Rottmann -- --=-=-=--