diff options
author | Richard Eisenberg <rae@richarde.dev> | 2020-10-14 18:12:45 -0400 |
---|---|---|
committer | Richard Eisenberg <rae@richarde.dev> | 2020-11-30 11:42:40 -0500 |
commit | 636db9ef27b04ac78ea4c7755fa9c93919d84722 (patch) | |
tree | 7890a7bb759f999ebb706236f8d224a97f4c3bce /compiler/GHC/Tc | |
parent | 0f8a4655e39bed1ca39820abdd3df9db5706b036 (diff) | |
download | haskell-636db9ef27b04ac78ea4c7755fa9c93919d84722.tar.gz |
Move core flattening algorithm to Core.Unify
This sets the stage for a later change, where this
algorithm will be needed from GHC.Core.InstEnv.
This commit also splits GHC.Core.Map into
GHC.Core.Map.Type and GHC.Core.Map.Expr,
in order to avoid module import cycles
with GHC.Core.
Diffstat (limited to 'compiler/GHC/Tc')
-rw-r--r-- | compiler/GHC/Tc/Errors.hs | 3 | ||||
-rw-r--r-- | compiler/GHC/Tc/Instance/Typeable.hs | 2 | ||||
-rw-r--r-- | compiler/GHC/Tc/Solver/Monad.hs | 4 |
3 files changed, 5 insertions, 4 deletions
diff --git a/compiler/GHC/Tc/Errors.hs b/compiler/GHC/Tc/Errors.hs index 37dc095f71..028d9b16a6 100644 --- a/compiler/GHC/Tc/Errors.hs +++ b/compiler/GHC/Tc/Errors.hs @@ -30,10 +30,9 @@ import GHC.Core.Type import GHC.Core.Coercion import GHC.Core.TyCo.Rep import GHC.Core.TyCo.Ppr ( pprTyVars, pprWithExplicitKindsWhen, pprSourceTyCon, pprWithTYPE ) -import GHC.Core.Unify ( tcMatchTys ) +import GHC.Core.Unify ( tcMatchTys, flattenTys ) import GHC.Unit.Module import GHC.Tc.Instance.Family -import GHC.Core.FamInstEnv ( flattenTys ) import GHC.Tc.Utils.Instantiate import GHC.Core.InstEnv import GHC.Core.TyCon diff --git a/compiler/GHC/Tc/Instance/Typeable.hs b/compiler/GHC/Tc/Instance/Typeable.hs index 01f18a7d6b..e4eb7a1b2d 100644 --- a/compiler/GHC/Tc/Instance/Typeable.hs +++ b/compiler/GHC/Tc/Instance/Typeable.hs @@ -40,7 +40,7 @@ import GHC.Hs import GHC.Driver.Session import GHC.Data.Bag import GHC.Types.Var ( VarBndr(..) ) -import GHC.Core.Map +import GHC.Core.Map.Type import GHC.Settings.Constants import GHC.Utils.Fingerprint(Fingerprint(..), fingerprintString, fingerprintFingerprints) import GHC.Utils.Outputable diff --git a/compiler/GHC/Tc/Solver/Monad.hs b/compiler/GHC/Tc/Solver/Monad.hs index 311eadc72e..64a80b2e94 100644 --- a/compiler/GHC/Tc/Solver/Monad.hs +++ b/compiler/GHC/Tc/Solver/Monad.hs @@ -178,7 +178,9 @@ import GHC.Types.Unique.DFM import GHC.Core.TyCon.Env import GHC.Data.Maybe -import GHC.Core.Map +import GHC.Core.Map.Type +import GHC.Data.TrieMap + import Control.Monad import GHC.Utils.Monad import Data.IORef |