ddc-core-0.2.1.2: Disciple Core language and type checker.

DDC.Type.Transform.Instantiate

Synopsis

instantiateT :: (Ord n, Pretty n) => Type n -> Type n -> Maybe (Type n)Source

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

Nothing

instantiateTs :: (Ord n, Pretty n) => Type n -> [Type n] -> Maybe (Type n)Source

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.