diff src/reduce.sml @ 193:8a70e2919e86

Specialization of single-parameter datatypes
author Adam Chlipala <adamc@hcoop.net>
date Fri, 08 Aug 2008 17:55:51 -0400
parents 7420fa18d657
children 2f574c07df2e
line wrap: on
line diff
--- a/src/reduce.sml	Fri Aug 08 10:59:06 2008 -0400
+++ b/src/reduce.sml	Fri Aug 08 17:55:51 2008 -0400
@@ -35,19 +35,7 @@
 structure U = CoreUtil
 
 val liftConInCon = E.liftConInCon
-
-val subConInCon =
-    U.Con.mapB {kind = fn k => k,
-                con = fn (xn, rep) => fn c =>
-                                  case c of
-                                      CRel xn' =>
-                                      (case Int.compare (xn', xn) of
-                                           EQUAL => #1 rep
-                                         | GREATER => CRel (xn' - 1)
-                                         | LESS => c)
-                                    | _ => c,
-                bind = fn ((xn, rep), U.Con.Rel _) => (xn+1, liftConInCon 0 rep)
-                        | (ctx, _) => ctx}
+val subConInCon = E.subConInCon
 
 val liftExpInExp =
     U.Exp.mapB {kind = fn k => k,