type-level-numbers-0.1.1.2: Type level numbers implemented using type families.
CopyrightAlexey Khudyakov
LicenseBSD3-style (see LICENSE)
MaintainerAlexey Khudyakov <alexey.skladnoy@gmail.com>
Stabilityunstable
Portabilityunportable (GHC only)
Safe HaskellSafe-Inferred
LanguageHaskell2010

TypeLevel.Reify

Description

 
Synopsis

Documentation

data Witness t a Source #

Value with type tag

Constructors

Witness 

Fields

Instances

Instances details
Eq a => Eq (Witness t a) Source # 
Instance details

Defined in TypeLevel.Reify

Methods

(==) :: Witness t a -> Witness t a -> Bool #

(/=) :: Witness t a -> Witness t a -> Bool #

(Data t, Data a) => Data (Witness t a) Source # 
Instance details

Defined in TypeLevel.Reify

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Witness t a -> c (Witness t a) #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (Witness t a) #

toConstr :: Witness t a -> Constr #

dataTypeOf :: Witness t a -> DataType #

dataCast1 :: Typeable t0 => (forall d. Data d => c (t0 d)) -> Maybe (c (Witness t a)) #

dataCast2 :: Typeable t0 => (forall d e. (Data d, Data e) => c (t0 d e)) -> Maybe (c (Witness t a)) #

gmapT :: (forall b. Data b => b -> b) -> Witness t a -> Witness t a #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Witness t a -> r #

gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Witness t a -> r #

gmapQ :: (forall d. Data d => d -> u) -> Witness t a -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> Witness t a -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Witness t a -> m (Witness t a) #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Witness t a -> m (Witness t a) #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Witness t a -> m (Witness t a) #

Show a => Show (Witness t a) Source # 
Instance details

Defined in TypeLevel.Reify

Methods

showsPrec :: Int -> Witness t a -> ShowS #

show :: Witness t a -> String #

showList :: [Witness t a] -> ShowS #

class Reify t a where Source #

Convert type level into value level using

Methods

witness :: Witness t a Source #

Instances

Instances details
Reify Z Int Source # 
Instance details

Defined in TypeLevel.Number.Nat

Reify Z Int8 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Reify Z Int16 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Reify Z Int32 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Reify Z Int64 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Reify Z Integer Source # 
Instance details

Defined in TypeLevel.Number.Nat

Reify Z Word8 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Reify Z Word16 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Reify Z Word32 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Reify Z Word64 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Reify False Bool Source # 
Instance details

Defined in TypeLevel.Boolean

Reify True Bool Source # 
Instance details

Defined in TypeLevel.Boolean

Nat (O n) => Reify (O n) Int64 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (O n) Int64 Source #

Nat (O n) => Reify (O n) Int32 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (O n) Int32 Source #

(Nat (O n), Lesser (O n) (O (O (O (O (O (O (O (O (O (O (O (O (O (O (O (I Z))))))))))))))))) => Reify (O n) Int16 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (O n) Int16 Source #

(Nat (O n), Lesser (O n) (O (O (O (O (O (O (O (I Z))))))))) => Reify (O n) Int8 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (O n) Int8 Source #

Nat (O n) => Reify (O n) Word64 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (O n) Word64 Source #

Nat (O n) => Reify (O n) Word32 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (O n) Word32 Source #

(Nat (O n), Lesser (O n) (O (O (O (O (O (O (O (O (O (O (O (O (O (O (O (O (I Z)))))))))))))))))) => Reify (O n) Word16 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (O n) Word16 Source #

(Nat (O n), Lesser (O n) (O (O (O (O (O (O (O (O (I Z)))))))))) => Reify (O n) Word8 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (O n) Word8 Source #

Nat (O n) => Reify (O n) Int Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (O n) Int Source #

Nat (O n) => Reify (O n) Integer Source # 
Instance details

Defined in TypeLevel.Number.Nat

Nat (I n) => Reify (I n) Int64 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (I n) Int64 Source #

Nat (I n) => Reify (I n) Int32 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (I n) Int32 Source #

(Nat (I n), Lesser (I n) (O (O (O (O (O (O (O (O (O (O (O (O (O (O (O (I Z))))))))))))))))) => Reify (I n) Int16 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (I n) Int16 Source #

(Nat (I n), Lesser (I n) (O (O (O (O (O (O (O (I Z))))))))) => Reify (I n) Int8 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (I n) Int8 Source #

Nat (I n) => Reify (I n) Word64 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (I n) Word64 Source #

Nat (I n) => Reify (I n) Word32 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (I n) Word32 Source #

(Nat (I n), Lesser (I n) (O (O (O (O (O (O (O (O (O (O (O (O (O (O (O (O (I Z)))))))))))))))))) => Reify (I n) Word16 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (I n) Word16 Source #

(Nat (I n), Lesser (I n) (O (O (O (O (O (O (O (O (I Z)))))))))) => Reify (I n) Word8 Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (I n) Word8 Source #

Nat (I n) => Reify (I n) Int Source # 
Instance details

Defined in TypeLevel.Number.Nat

Methods

witness :: Witness (I n) Int Source #

Nat (I n) => Reify (I n) Integer Source # 
Instance details

Defined in TypeLevel.Number.Nat