Commit 289be612 authored by Simon Peyton Jones's avatar Simon Peyton Jones

Remove dead code

parent 355d57a5
......@@ -81,8 +81,6 @@ module TcSMonad (
newFlexiTcSTy, instFlexiTcS, instFlexiTcSHelperTcS,
cloneMetaTyVar,
mkKindErrorCtxtTcS,
Untouchables, isTouchableMetaTyVarTcS, isFilledMetaTyVar_maybe,
zonkTyVarsAndFV,
......@@ -110,7 +108,6 @@ import qualified TcRnMonad as TcM
import qualified TcMType as TcM
import qualified TcEnv as TcM
( checkWellStaged, topIdLvl, tcGetDefaultTys )
import {-# SOURCE #-} qualified TcUnify as TcM ( mkKindErrorCtxt )
import Kind
import TcType
import DynFlags
......@@ -147,15 +144,6 @@ import Digraph
#endif
\end{code}
\begin{code}
mkKindErrorCtxtTcS :: Type -> Kind
-> Type -> Kind
-> ErrCtxt
mkKindErrorCtxtTcS ty1 ki1 ty2 ki2
= (False,TcM.mkKindErrorCtxt ty1 ty2 ki1 ki2)
\end{code}
%************************************************************************
%* *
%* Worklists *
......
......@@ -31,11 +31,7 @@ module TcUnify (
matchExpectedAppTy,
matchExpectedFunTys,
matchExpectedFunKind,
wrapFunResCoercion,
--------------------------------
-- Errors
mkKindErrorCtxt
wrapFunResCoercion
) where
......@@ -1200,19 +1196,4 @@ uUnboundKVar kv1 non_var_k2
; case occurCheckExpand dflags kv1 k2b of
OC_OK k2c -> do { writeMetaTyVar kv1 k2c; return (Just EQ) }
_ -> return Nothing }
mkKindErrorCtxt :: Type -> Type -> Kind -> Kind -> TidyEnv -> TcM (TidyEnv, SDoc)
mkKindErrorCtxt ty1 ty2 k1 k2 env0
= let (env1, ty1') = tidyOpenType env0 ty1
(env2, ty2') = tidyOpenType env1 ty2
(env3, k1' ) = tidyOpenKind env2 k1
(env4, k2' ) = tidyOpenKind env3 k2
in do ty1 <- zonkTcType ty1'
ty2 <- zonkTcType ty2'
k1 <- zonkTcKind k1'
k2 <- zonkTcKind k2'
return (env4,
vcat [ ptext (sLit "Kind incompatibility when matching types xx:")
, nest 2 (vcat [ ppr ty1 <+> dcolon <+> ppr k1
, ppr ty2 <+> dcolon <+> ppr k2 ]) ])
\end{code}
\begin{code}
module TcUnify where
import TcType ( TcTauType, Type, Kind )
import VarEnv ( TidyEnv )
import TcType ( TcTauType )
import TcRnTypes ( TcM )
import TcEvidence ( TcCoercion )
import Outputable ( SDoc )
-- This boot file exists only to tie the knot between
-- TcUnify and Inst
unifyType :: TcTauType -> TcTauType -> TcM TcCoercion
mkKindErrorCtxt :: Type -> Type -> Kind -> Kind -> TidyEnv -> TcM (TidyEnv, SDoc)
\end{code}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment