Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- datatypes ∷ Term TyName Name DefaultUni DefaultFun () → [(TyName, Kind ())]
- inferTypeInContext ∷ TypeCtx → Map Name (Type TyName DefaultUni ()) → Term TyName Name DefaultUni DefaultFun () → Either String (Type TyName DefaultUni ())
- typeCheckTerm ∷ Term TyName Name DefaultUni DefaultFun () → Type TyName DefaultUni () → Either String ()
- typeCheckTermInContext ∷ TypeCtx → Map Name (Type TyName DefaultUni ()) → Term TyName Name DefaultUni DefaultFun () → Type TyName DefaultUni () → Either String ()
Documentation
datatypes ∷ Term TyName Name DefaultUni DefaultFun () → [(TyName, Kind ())] Source #
Compute the datatype declarations that escape from a term.
inferTypeInContext ∷ TypeCtx → Map Name (Type TyName DefaultUni ()) → Term TyName Name DefaultUni DefaultFun () → Either String (Type TyName DefaultUni ()) Source #
Try to infer the type of an expression in a given type and term context.
NOTE: one can't just use out-of-the-box type inference here because the
inferType
algorithm happy renames things.
typeCheckTerm ∷ Term TyName Name DefaultUni DefaultFun () → Type TyName DefaultUni () → Either String () Source #
typeCheckTermInContext ∷ TypeCtx → Map Name (Type TyName DefaultUni ()) → Term TyName Name DefaultUni DefaultFun () → Type TyName DefaultUni () → Either String () Source #