diff src/core_util.sml @ 482:9117a7bf229c

Especialize working reasonably well; need to add new closure representation pass
author Adam Chlipala <adamc@hcoop.net>
date Sun, 09 Nov 2008 11:53:52 -0500
parents ffa18975e661
children 685b41e85634
line wrap: on
line diff
--- a/src/core_util.sml	Sat Nov 08 16:47:04 2008 -0500
+++ b/src/core_util.sml	Sun Nov 09 11:53:52 2008 -0500
@@ -953,6 +953,13 @@
         S.Continue (ds, ()) => ds
       | S.Return _ => raise Fail "CoreUtil.File.mapB: Impossible"
 
+fun map {kind, con, exp, decl} ds =
+    mapB {kind = kind,
+          con = fn () => con,
+          exp = fn () => exp,
+          decl = fn () => decl,
+          bind = fn _ => ()} () ds
+
 fun fold {kind, con, exp, decl} s d =
     case mapfold {kind = fn k => fn s => S.Continue (k, kind (k, s)),
                   con = fn c => fn s => S.Continue (c, con (c, s)),