Mercurial > urweb
diff src/corify.sml @ 45:3c1ce1b4eb3d
Explifying functors
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Thu, 19 Jun 2008 17:11:24 -0400 |
parents | 02f42e9a1825 |
children | 44a1bc863f0f |
line wrap: on
line diff
--- a/src/corify.sml Thu Jun 19 17:04:08 2008 -0400 +++ b/src/corify.sml Thu Jun 19 17:11:24 2008 -0400 @@ -257,6 +257,8 @@ in (ds, {inner = St.lookupStrByName (x, inner), outer = outer}) end + | L.StrFun _ => raise Fail "Corify functor" + | L.StrApp _ => raise Fail "Corify functor app" fun maxName ds = foldl (fn ((d, _), n) => case d of @@ -271,6 +273,8 @@ L.StrConst ds => maxName ds | L.StrVar n => n | L.StrProj (str, _) => maxNameStr str + | L.StrFun (_, _, _, _, str) => maxNameStr str + | L.StrApp (str1, str2) => Int.max (maxNameStr str1, maxNameStr str2) fun corify ds = let