ddc-core-0.4.3.1: Disciplined Disciple Compiler core language and type checker.

DDC.Type.Transform.Instantiate

Synopsis

# Documentation

Arguments

 :: Ord n => Type n Type to instantiate. -> Type n Argument type. -> Maybe (Type n)

Instantiate a type with an argument. The type to be instantiated must have an outer forall, else Nothing.

Arguments

 :: Ord n => Type n Type to instantiate. -> [Type n] Argument types. -> Maybe (Type n)

Instantiate a type with several arguments. The type to be instantiated must have at least as many outer foralls as provided type arguments, else Nothing.