hydra-0.5.1: Type-aware transformations for data and programs
Safe HaskellSafe-Inferred
LanguageHaskell2010

Hydra.Phantoms

Description

Phantom types for use in model definitions

Synopsis

Documentation

newtype Case a Source #

An association of a field name (as in a case statement) with a phantom type

Constructors

Case 

Fields

Instances

Instances details
Read (Case a) Source # 
Instance details

Defined in Hydra.Phantoms

Show (Case a) Source # 
Instance details

Defined in Hydra.Phantoms

Methods

showsPrec :: Int -> Case a -> ShowS #

show :: Case a -> String #

showList :: [Case a] -> ShowS #

Eq (Case a) Source # 
Instance details

Defined in Hydra.Phantoms

Methods

(==) :: Case a -> Case a -> Bool #

(/=) :: Case a -> Case a -> Bool #

Ord (Case a) Source # 
Instance details

Defined in Hydra.Phantoms

Methods

compare :: Case a -> Case a -> Ordering #

(<) :: Case a -> Case a -> Bool #

(<=) :: Case a -> Case a -> Bool #

(>) :: Case a -> Case a -> Bool #

(>=) :: Case a -> Case a -> Bool #

max :: Case a -> Case a -> Case a #

min :: Case a -> Case a -> Case a #

newtype Datum a Source #

An association of a term with a phantom type

Constructors

Datum 

Fields

Instances

Instances details
IsString (Datum a) Source # 
Instance details

Defined in Hydra.Dsl.Base

Methods

fromString :: String -> Datum a #

Read (Datum a) Source # 
Instance details

Defined in Hydra.Phantoms

Show (Datum a) Source # 
Instance details

Defined in Hydra.Phantoms

Methods

showsPrec :: Int -> Datum a -> ShowS #

show :: Datum a -> String #

showList :: [Datum a] -> ShowS #

Eq (Datum a) Source # 
Instance details

Defined in Hydra.Phantoms

Methods

(==) :: Datum a -> Datum a -> Bool #

(/=) :: Datum a -> Datum a -> Bool #

Ord (Datum a) Source # 
Instance details

Defined in Hydra.Phantoms

Methods

compare :: Datum a -> Datum a -> Ordering #

(<) :: Datum a -> Datum a -> Bool #

(<=) :: Datum a -> Datum a -> Bool #

(>) :: Datum a -> Datum a -> Bool #

(>=) :: Datum a -> Datum a -> Bool #

max :: Datum a -> Datum a -> Datum a #

min :: Datum a -> Datum a -> Datum a #

data Definition a Source #

An association with a named term with a phantom type

Constructors

Definition 

Instances

Instances details
Read (Definition a) Source # 
Instance details

Defined in Hydra.Phantoms

Show (Definition a) Source # 
Instance details

Defined in Hydra.Phantoms

Eq (Definition a) Source # 
Instance details

Defined in Hydra.Phantoms

Methods

(==) :: Definition a -> Definition a -> Bool #

(/=) :: Definition a -> Definition a -> Bool #

Ord (Definition a) Source # 
Instance details

Defined in Hydra.Phantoms

newtype Fld a Source #

An association with a term-level field with a phantom type

Constructors

Fld 

Fields

Instances

Instances details
Read (Fld a) Source # 
Instance details

Defined in Hydra.Phantoms

Show (Fld a) Source # 
Instance details

Defined in Hydra.Phantoms

Methods

showsPrec :: Int -> Fld a -> ShowS #

show :: Fld a -> String #

showList :: [Fld a] -> ShowS #

Eq (Fld a) Source # 
Instance details

Defined in Hydra.Phantoms

Methods

(==) :: Fld a -> Fld a -> Bool #

(/=) :: Fld a -> Fld a -> Bool #

Ord (Fld a) Source # 
Instance details

Defined in Hydra.Phantoms

Methods

compare :: Fld a -> Fld a -> Ordering #

(<) :: Fld a -> Fld a -> Bool #

(<=) :: Fld a -> Fld a -> Bool #

(>) :: Fld a -> Fld a -> Bool #

(>=) :: Fld a -> Fld a -> Bool #

max :: Fld a -> Fld a -> Fld a #

min :: Fld a -> Fld a -> Fld a #

data Reference a Source #

A pure association with a phantom type

Constructors

Reference 

Instances

Instances details
Read (Reference a) Source # 
Instance details

Defined in Hydra.Phantoms

Show (Reference a) Source # 
Instance details

Defined in Hydra.Phantoms

Eq (Reference a) Source # 
Instance details

Defined in Hydra.Phantoms

Methods

(==) :: Reference a -> Reference a -> Bool #

(/=) :: Reference a -> Reference a -> Bool #

Ord (Reference a) Source # 
Instance details

Defined in Hydra.Phantoms