diff options
author | Adam Chlipala <adam@chlipala.net> | 2011-11-02 08:39:01 -0400 |
---|---|---|
committer | Adam Chlipala <adam@chlipala.net> | 2011-11-02 08:39:01 -0400 |
commit | fcefdc8081f30d44e71dfd54ff1a13a963ac1d1a (patch) | |
tree | 01c6d3cb57e0d0cb94ee25567dc644af38a940a0 /src/elaborate.sml | |
parent | 7be772d91d592c9a1ec201fb4bc07e8dd1f5a9f5 (diff) |
Handle application in decompileCon
Diffstat (limited to 'src/elaborate.sml')
-rw-r--r-- | src/elaborate.sml | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/elaborate.sml b/src/elaborate.sml index 9051299a..93c15ed2 100644 --- a/src/elaborate.sml +++ b/src/elaborate.sml @@ -3441,7 +3441,12 @@ and wildifyStr env (str, sgn) = | L'.CUnit => SOME (L.CUnit, loc) | L'.CUnif (nl, _, _, _, ref (SOME c)) => decompileCon env (E.mliftConInCon nl c) - | _ => NONE + | L'.CApp (f, x) => + (case (decompileCon env f, decompileCon env x) of + (SOME f, SOME x) => SOME (L.CApp (f, x), loc) + | _ => NONE) + + | c => (Print.preface ("WTF?", p_con env (c, loc)); NONE) fun buildNeeded env sgis = #1 (foldl (fn ((sgi, loc), (nd, env')) => @@ -3507,7 +3512,9 @@ and wildifyStr env (str, sgn) = case (decompileCon env' c1, decompileCon env' c2) of (SOME c1, SOME c2) => SOME (L.DConstraint (c1, c2), loc) - | _ => NONE) (nconstraints nd) + | _ => (Print.prefaces "BAD" [("c1", p_con env' c1), + ("c2", p_con env' c2)]; + NONE)) (nconstraints nd) val ds' = case SS.listItems (nvals nd) of |