projects
/
ghc-hetmet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Cross-module consistency check for family instances
[ghc-hetmet.git]
/
compiler
/
typecheck
/
TcRnDriver.lhs
diff --git
a/compiler/typecheck/TcRnDriver.lhs
b/compiler/typecheck/TcRnDriver.lhs
index
94c55a7
..
696e41b
100644
(file)
--- a/
compiler/typecheck/TcRnDriver.lhs
+++ b/
compiler/typecheck/TcRnDriver.lhs
@@
-37,6
+37,7
@@
import TcExpr
import TcRnMonad
import TcType
import Inst
import TcRnMonad
import TcType
import Inst
+import FamInst
import InstEnv
import FamInstEnv
import TcBinds
import InstEnv
import FamInstEnv
import TcBinds
@@
-173,6
+174,12
@@
tcRnModule hsc_env hsc_src save_rn_syntax
loadOrphanModules (imp_orphs imports) False ;
loadOrphanModules (imp_finsts imports) True ;
loadOrphanModules (imp_orphs imports) False ;
loadOrphanModules (imp_finsts imports) True ;
+ let { directlyImpMods = map (\(mod, _, _) -> mod)
+ . moduleEnvElts
+ . imp_mods
+ $ imports } ;
+ checkFamInstConsistency (imp_finsts imports) directlyImpMods ;
+
traceRn (text "rn1a") ;
-- Rename and type check the declarations
tcg_env <- if isHsBoot hsc_src then
traceRn (text "rn1a") ;
-- Rename and type check the declarations
tcg_env <- if isHsBoot hsc_src then