ghc-8.10.7: The GHC API
Safe HaskellNone
LanguageHaskell2010

TcEnv

Synopsis

Documentation

data TyThing #

A global typecheckable-thing, essentially anything that has a name. Not to be confused with a TcTyThing, which is also a typecheckable thing but in the *local* context. See TcEnv for how to retrieve a TyThing given a Name.

Instances

Instances details
Outputable TyThing # 
Instance details

Defined in TyCoRep

Methods

ppr :: TyThing -> SDoc #

pprPrec :: Rational -> TyThing -> SDoc #

NamedThing TyThing # 
Instance details

Defined in TyCoRep

data TcTyThing #

A typecheckable thing available in a local context. Could be AGlobal TyThing, but also lexically scoped variables, etc. See TcEnv for how to retrieve a TyThing given a Name.

Instances

Instances details
Outputable TcTyThing # 
Instance details

Defined in TcRnTypes

type TcId = Id #

data InstInfo a #

Constructors

InstInfo 

Fields

Instances

Instances details
OutputableBndrId a => Outputable (InstInfo (GhcPass a)) # 
Instance details

Defined in TcEnv

Methods

ppr :: InstInfo (GhcPass a) -> SDoc #

pprPrec :: Rational -> InstInfo (GhcPass a) -> SDoc #

tcExtendTyConEnv :: [TyCon] -> TcM r -> TcM r #

tcExtendTyVarEnv :: [TyVar] -> TcM r -> TcM r #

tcExtendRecIds :: [(Name, TcId)] -> TcM a -> TcM a #

tcExtendIdEnv :: [TcId] -> TcM a -> TcM a #

tcExtendIdEnv1 :: Name -> TcId -> TcM a -> TcM a #

tcExtendIdEnv2 :: [(Name, TcId)] -> TcM a -> TcM a #

tcExtendRecEnv :: [(Name, TyThing)] -> TcM r -> TcM r #

tcInitOpenTidyEnv :: [TyCoVar] -> TcM TidyEnv #

Get a TidyEnv that includes mappings for all vars free in the given type. Useful when tidying open types.

newDFunName :: Class -> [Type] -> SrcSpan -> TcM Name #

Make a name for the dict fun for an instance decl. It's an *external* name, like other top-level names, and hence must be made with newGlobalBinder.

Orphan instances