guile-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Guile-commits] GNU Guile branch, mlucy, updated. release_1-9-11-164-gf4


From: Michael Lucy
Subject: [Guile-commits] GNU Guile branch, mlucy, updated. release_1-9-11-164-gf4f3d10
Date: Mon, 16 Aug 2010 05:12:18 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Guile".

http://git.savannah.gnu.org/cgit/guile.git/commit/?id=f4f3d10ba4c37ba809a8e62005f0923fd4334eba

The branch, mlucy has been updated
       via  f4f3d10ba4c37ba809a8e62005f0923fd4334eba (commit)
      from  d0b4bf1807fa9568b7291142fa56ded72f91abd5 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit f4f3d10ba4c37ba809a8e62005f0923fd4334eba
Author: Michael Lucy <address@hidden>
Date:   Mon Aug 16 00:12:07 2010 -0500

    Actually done.

-----------------------------------------------------------------------

Summary of changes:
 module/ice-9/peg.scm |   24 ++++++++++++++++--------
 1 files changed, 16 insertions(+), 8 deletions(-)

diff --git a/module/ice-9/peg.scm b/module/ice-9/peg.scm
index b8613c0..2386001 100644
--- a/module/ice-9/peg.scm
+++ b/module/ice-9/peg.scm
@@ -25,19 +25,27 @@
 ;;  `(,a ,b))
 ;; gives:
 ;; (#<uninterned-symbol a cc608d0> #<uninterned-symbol b cc608a0>)
-(define-macro (safe-bind vals . actions)
-  (apply safe-bind-f (cons vals actions)))
+(define-syntax safe-bind
+  (lambda (x)
+    (syntax-case x ()
+      ((_ vals . actions)
+       (datum->syntax x (apply safe-bind-f
+                               (cons
+                                (syntax->datum #'vals)
+                                (syntax->datum #'actions))))))))
+;; (define-macro (safe-bind vals . actions)
+;;   (apply safe-bind-f (cons vals actions)))
 (define (safe-bind-f vals . actions)
   `(let ,(map (lambda (val) `(,val (make-symbol ,(symbol->string val)))) vals)
      ,@actions))
 
 ;; Unsafe-bind is like safe-bind but uses symbols that are easier to read while
-;; debugging rather than safe ones.
-(define-macro (unsafe-bind vals . actions)
-  (apply unsafe-bind-f (cons vals actions)))
-(define (unsafe-bind-f vals . actions)
-  `(let ,(map (lambda (val) `(,val ',val)) vals)
-     ,@actions))
+;; debugging rather than safe ones.  Currently unused.
+;; (define-macro (unsafe-bind vals . actions)
+;;   (apply unsafe-bind-f (cons vals actions)))
+;; (define (unsafe-bind-f vals . actions)
+;;   `(let ,(map (lambda (val) `(,val ',val)) vals)
+;;      ,@actions))
 
 
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ;;;;; LOOPING CONSTRUCTS


hooks/post-receive
-- 
GNU Guile



reply via email to

[Prev in Thread] Current Thread [Next in Thread]