Safe Haskell | None |
---|---|
Language | GHC2021 |
Synopsis
- matchGlobalInst :: DynFlags -> Bool -> Class -> [Type] -> Maybe CtLoc -> TcM ClsInstResult
- matchEqualityInst :: Class -> [Type] -> (DataCon, Role, Type, Type)
- data ClsInstResult
- = NoInstance
- | OneInst {
- cir_new_theta :: [TcPredType]
- cir_mk_ev :: [EvExpr] -> EvTerm
- cir_canonical :: CanonicalEvidence
- cir_what :: InstanceWhat
- | NotSure
- data InstanceWhat
- safeOverlap :: InstanceWhat -> Bool
- instanceReturnsDictCon :: InstanceWhat -> Bool
- data AssocInstInfo
- = NotAssociated
- | InClsInst { }
- isNotAssociated :: AssocInstInfo -> Bool
- lookupHasFieldLabel :: FamInstEnvs -> GlobalRdrEnv -> [Type] -> Maybe (Name, GlobalRdrElt, Type, Type)
Documentation
data ClsInstResult Source #
NoInstance | |
OneInst | |
| |
NotSure |
Instances
Outputable ClsInstResult Source # | |
Defined in GHC.Tc.Instance.Class ppr :: ClsInstResult -> SDoc Source # |
data InstanceWhat Source #
BuiltinEqInstance | |
BuiltinTypeableInstance TyCon | |
BuiltinInstance | |
LocalInstance | |
TopLevInstance | |
|
Instances
Outputable InstanceWhat Source # | |
Defined in GHC.Tc.Types.Origin ppr :: InstanceWhat -> SDoc Source # |
safeOverlap :: InstanceWhat -> Bool Source #
data AssocInstInfo Source #
Extra information about the parent instance declaration, needed
when type-checking associated types. The Class
is the enclosing
class, the [TyVar] are the scoped type variable of the instance decl.
The VarEnv Type
maps class variables to their instance types.
NotAssociated | |
InClsInst | |
|
isNotAssociated :: AssocInstInfo -> Bool Source #
lookupHasFieldLabel :: FamInstEnvs -> GlobalRdrEnv -> [Type] -> Maybe (Name, GlobalRdrElt, Type, Type) Source #