summaryrefslogtreecommitdiff
path: root/compiler/deSugar/DsMeta.hs
diff options
context:
space:
mode:
authorSimon Peyton Jones <simonpj@microsoft.com>2018-08-21 15:57:56 +0100
committerSimon Peyton Jones <simonpj@microsoft.com>2018-08-21 16:03:21 +0100
commit43b08cfbac5ce7ad6fc245651329094896de06e0 (patch)
tree9011abea19ca52380cbbff8fcaf2a9fbaddc9512 /compiler/deSugar/DsMeta.hs
parent828e949318399752630f80f1fbefbbea08c55995 (diff)
downloadhaskell-43b08cfbac5ce7ad6fc245651329094896de06e0.tar.gz
Add a solveEqualities to tcClassDecl1
Trac #15505 showed that, when we have a type error, we could have an unfilled-in coercion hole. We don't want an assertion error in that case. The underlying cause is that tcClassDecl1 should call solveEqualities to fully solve all top-level equalities (or fail in the attempt). I also refactored the ClassDecl case for tcTyClDecl1 into a new function tcClassDecl1. That makes it symmetrical with the others.
Diffstat (limited to 'compiler/deSugar/DsMeta.hs')
-rw-r--r--compiler/deSugar/DsMeta.hs4
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/deSugar/DsMeta.hs b/compiler/deSugar/DsMeta.hs
index ed2c612e94..085cfc5ec3 100644
--- a/compiler/deSugar/DsMeta.hs
+++ b/compiler/deSugar/DsMeta.hs
@@ -470,10 +470,10 @@ repAssocTyFamDefaults = mapM rep_deflt
-------------------------
-- represent fundeps
--
-repLFunDeps :: [Located (FunDep (Located Name))] -> DsM (Core [TH.FunDep])
+repLFunDeps :: [LHsFunDep GhcRn] -> DsM (Core [TH.FunDep])
repLFunDeps fds = repList funDepTyConName repLFunDep fds
-repLFunDep :: Located (FunDep (Located Name)) -> DsM (Core TH.FunDep)
+repLFunDep :: LHsFunDep GhcRn -> DsM (Core TH.FunDep)
repLFunDep (L _ (xs, ys))
= do xs' <- repList nameTyConName (lookupBinder . unLoc) xs
ys' <- repList nameTyConName (lookupBinder . unLoc) ys