ghc-8.4.2: The GHC API

Kind

Synopsis

# Main data type

type Kind = Type Source #

The key type representing kinds in the compiler.

## Predicates on Kinds

This version considers Constraint to be distinct from *. Returns True if the argument is equivalent to Type and False otherwise.

Returns True if the kind classifies unlifted types and False otherwise. Note that this returns False for levity-polymorphic kinds, which may be specialized to a kind that classifies unlifted types.

Does the given type "end" in the given tycon? For example k -> [a] -> * ends in * and Maybe a -> [a] ends in [].

Does this classify a type allowed to have values? Responds True to things like *, #, TYPE Lifted, TYPE v, Constraint.

True of any sub-kind of OpenTypeKind

Is this kind equivalent to *?

Is the tycon Constraint?

Is this kind equivalent to *?

Tests whether the given kind (which should look like TYPE x) is something other than a constructor tree (that is, constructors at every node).