diff src/corify.sml @ 461:5c9606deacb6

Cookies through shake2
author Adam Chlipala <adamc@hcoop.net>
date Thu, 06 Nov 2008 10:48:02 -0500
parents 1a4fa157fedd
children 40c737913075
line wrap: on
line diff
--- a/src/corify.sml	Thu Nov 06 10:43:48 2008 -0500
+++ b/src/corify.sml	Thu Nov 06 10:48:02 2008 -0500
@@ -981,6 +981,14 @@
 
       | L.DDatabase s => ([(L'.DDatabase s, loc)], st)
 
+      | L.DCookie (_, x, n, c) =>
+        let
+            val (st, n) = St.bindVal st x n
+            val s = doRestify (mods, x)
+        in
+            ([(L'.DCookie (x, n, corifyCon st c, s), loc)], st)
+        end
+
 and corifyStr mods ((str, _), st) =
     case str of
         L.StrConst ds =>
@@ -1034,7 +1042,8 @@
                              | L.DExport _ => n
                              | L.DTable (_, _, n', _) => Int.max (n, n')
                              | L.DSequence (_, _, n') => Int.max (n, n')
-                             | L.DDatabase _ => n)
+                             | L.DDatabase _ => n
+                             | L.DCookie (_, _, n', _) => Int.max (n, n'))
                        0 ds
 
 and maxNameStr (str, _) =