Remove some hardcoded makefile settings
[ghc-hetmet.git] / compiler / basicTypes / Var.lhs
index a0fa921..79fad32 100644 (file)
@@ -50,7 +50,7 @@ module Var (
        mkTyVar, mkTcTyVar, mkWildCoVar,
 
        -- ** Taking 'TyVar's apart
-       tyVarName, tyVarKind, tcTyVarDetails,
+        tyVarName, tyVarKind, tcTyVarDetails, setTcTyVarDetails,
 
        -- ** Modifying 'TyVar's
        setTyVarName, setTyVarUnique, setTyVarKind,
@@ -181,7 +181,8 @@ instance Outputable Var where
   ppr var = ppr (varName var) <+> ifPprDebug (brackets (ppr_debug var))
 
 ppr_debug :: Var -> SDoc
-ppr_debug (TyVar {})                          = ptext (sLit "tv")
+ppr_debug (TyVar { isCoercionVar = False })   = ptext (sLit "tv")
+ppr_debug (TyVar { isCoercionVar = True })    = ptext (sLit "co")
 ppr_debug (TcTyVar {tc_tv_details = d})       = pprTcTyVarDetails d
 ppr_debug (Id { idScope = s, id_details = d }) = ppr_id_scope s <> pprIdDetails d
 
@@ -282,6 +283,9 @@ mkTcTyVar name kind details
 tcTyVarDetails :: TyVar -> TcTyVarDetails
 tcTyVarDetails (TcTyVar { tc_tv_details = details }) = details
 tcTyVarDetails var = pprPanic "tcTyVarDetails" (ppr var)
+
+setTcTyVarDetails :: TyVar -> TcTyVarDetails -> TyVar
+setTcTyVarDetails tv details = tv { tc_tv_details = details }
 \end{code}
 
 %************************************************************************