Author: Juergen Boemmels <[email protected]>
Branch: 
Changeset: r22:195698c3612c
Date: 2011-11-29 21:47 +0100
http://bitbucket.org/pypy/lang-scheme/changeset/195698c3612c/

Log:    Mock-up Implementation of for-each

diff --git a/scheme/procedure.py b/scheme/procedure.py
--- a/scheme/procedure.py
+++ b/scheme/procedure.py
@@ -262,6 +262,14 @@
         # XXX need to find out how to do this tailrecusive
         return (Reverse().procedure(ctx,[w_rev_result]), None)
 
+class ForEach(W_Procedure):
+    _symbol_name = "for-each"
+
+    def procedure_tr(self, ctx, lst):
+        # simply relay to map and ignore output
+        (res, ctx) = Map().procedure_tr(ctx, lst)
+        return (w_undefined, ctx)
+    
 ##
 # Equivalnece Predicates
 ##
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to