ty-0.1.6: Typed type representations and equality proofs

Stabilityexperimental
Maintainerconal@conal.net
Safe HaskellNone

Data.Ty

Description

Typed typerefs

Synopsis

Documentation

class Typeable a

The class Typeable allows a concrete representation of a type to be calculated.

module Data.IsTy

data Ty a Source

Phantom type wrapper around a TypeRep

Instances

IsTy Ty 
Eq (Ty a) 
Show (Ty a) 

ty :: Typeable a => Ty aSource

tyOf :: Typeable a => a -> Ty aSource

The Ty of a value

tyOf1 :: forall f a. Typeable a => f a -> Ty aSource

The Ty of a value from a constructor application

tyOf2 :: forall g f a. Typeable a => g (f a) -> Ty aSource

The Ty of a value from a nested constructor application

(=:=) :: forall a b. (Typeable a, Typeable b, Eq a) => a -> b -> Maybe (a :=: b)Source

Equality of typed values. Just Refl means the the types match and the values match.

data AsPairTy whereSource

Constructors

PairTy :: Ty a -> Ty b -> AsPairTy (a, b)