diff src/mono_env.sml @ 109:813e5a52063d

Remove closure conversion in favor of zany fun with modules, which also replaces 'page'
author Adam Chlipala <adamc@hcoop.net>
date Sun, 13 Jul 2008 10:17:06 -0400
parents f0f59e918cac
children 76a4d69719d8
line wrap: on
line diff
--- a/src/mono_env.sml	Thu Jul 10 16:05:14 2008 -0400
+++ b/src/mono_env.sml	Sun Jul 13 10:17:06 2008 -0400
@@ -39,7 +39,7 @@
      namedT : (string * typ option) IM.map,
 
      relE : (string * typ) list,
-     namedE : (string * typ * exp option) IM.map
+     namedE : (string * typ * exp option * string) IM.map
 }
 
 val empty = {
@@ -70,11 +70,11 @@
     (List.nth (#relE env, n))
     handle Subscript => raise UnboundRel n
 
-fun pushENamed (env : env) x n t eo =
+fun pushENamed (env : env) x n t eo s =
     {namedT = #namedT env,
 
      relE = #relE env,
-     namedE = IM.insert (#namedE env, n, (x, t, eo))}
+     namedE = IM.insert (#namedE env, n, (x, t, eo, s))}
 
 fun lookupENamed (env : env) n =
     case IM.find (#namedE env, n) of
@@ -83,7 +83,7 @@
 
 fun declBinds env (d, _) =
     case d of
-        DVal (x, n, t, e) => pushENamed env x n t (SOME e)
-      | DPage _ => env
+        DVal (x, n, t, e, s) => pushENamed env x n t (SOME e) s
+      | DExport _ => env
 
 end