Mercurial > urweb
diff src/elab_util.sml @ 2190:22117edf8fd3
After a tricky debugging session, limit visibility of type-class instances from anonymous modules
author | Adam Chlipala <adam@chlipala.net> |
---|---|
date | Sun, 01 Nov 2015 16:33:14 -0500 |
parents | 403f0cc65b9c |
children | 1091227f535a |
line wrap: on
line diff
--- a/src/elab_util.sml Sun Nov 01 14:17:09 2015 -0500 +++ b/src/elab_util.sml Sun Nov 01 16:33:14 2015 -0500 @@ -688,10 +688,10 @@ S.map2 (con ctx c, fn c' => (SgiVal (x, n, c'), loc)) - | SgiStr (x, n, s) => + | SgiStr (im, x, n, s) => S.map2 (sg ctx s, fn s' => - (SgiStr (x, n, s'), loc)) + (SgiStr (im, x, n, s'), loc)) | SgiSgn (x, n, s) => S.map2 (sg ctx s, fn s' => @@ -738,7 +738,7 @@ bind (ctx, NamedC (x, n, (KType, loc), SOME (CModProj (m1, ms, s), loc))) | SgiVal _ => ctx - | SgiStr (x, n, sgn) => + | SgiStr (_, x, n, sgn) => bind (ctx, Str (x, n, sgn)) | SgiSgn (x, n, sgn) => bind (ctx, Sgn (x, n, sgn)) @@ -1270,7 +1270,7 @@ foldl (fn ((_, n', _), m) => Int.max (n', m)) (Int.max (n1, n2)) ns | SgiVal (_, n, _) => n - | SgiStr (_, n, sgn) => Int.max (n, maxNameSgn sgn) + | SgiStr (_, _, n, sgn) => Int.max (n, maxNameSgn sgn) | SgiSgn (_, n, sgn) => Int.max (n, maxNameSgn sgn) | SgiConstraint _ => 0 | SgiClassAbs (_, n, _) => n