Mercurial > urweb
diff src/corify.sml @ 162:06a98129b23f
Add datatype import constructor annotations; datatypes through explify
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Tue, 29 Jul 2008 12:30:04 -0400 |
parents | 7420fa18d657 |
children | 80192edca30d |
line wrap: on
line diff
--- a/src/corify.sml Thu Jul 24 16:51:24 2008 -0400 +++ b/src/corify.sml Tue Jul 29 12:30:04 2008 -0400 @@ -384,6 +384,8 @@ in ([(L'.DCon (x, n, corifyKind k, corifyCon st c), loc)], st) end + | L.DDatatype _ => raise Fail "Corify DDatatype" + | L.DDatatypeImp _ => raise Fail "Corify DDatatypeImp" | L.DVal (x, n, t, e) => let val (st, n) = St.bindVal st x n @@ -568,6 +570,8 @@ fun maxName ds = foldl (fn ((d, _), n) => case d of L.DCon (_, n', _, _) => Int.max (n, n') + | L.DDatatype (_, n', _) => Int.max (n, n') + | L.DDatatypeImp (_, n', _, _, _, _) => Int.max (n, n') | L.DVal (_, n', _, _) => Int.max (n, n') | L.DValRec vis => foldl (fn ((_, n', _, _), n) => Int.max (n, n)) n vis | L.DSgn (_, n', _) => Int.max (n, n')