witness-0.7: values that witness types
Safe HaskellNone
LanguageGHC2021

Data.Type.Witness.General.Order

Documentation

data WOrdering (a :: k) (b :: k) where Source #

Constructors

WLT :: forall k (a :: k) (b :: k). WOrdering a b 
WEQ :: forall k (a :: k). WOrdering a a 
WGT :: forall k (a :: k) (b :: k). WOrdering a b 

wOrderingToOrdering :: forall {k} (a :: k) (b :: k). WOrdering a b -> Ordering Source #

class TestEquality w => TestOrder (w :: k -> Type) where Source #

Methods

testCompare :: forall (a :: k) (b :: k). w a -> w b -> WOrdering a b Source #

Instances

Instances details
TestOrder NaturalType Source # 
Instance details

Defined in Data.Type.Witness.Specific.Natural

Methods

testCompare :: forall (a :: Nat) (b :: Nat). NaturalType a -> NaturalType b -> WOrdering a b Source #

TestOrder PeanoNatType Source # 
Instance details

Defined in Data.Type.Witness.Specific.PeanoNat

Methods

testCompare :: forall (a :: PeanoNat) (b :: PeanoNat). PeanoNatType a -> PeanoNatType b -> WOrdering a b Source #

TestOrder SymbolType Source # 
Instance details

Defined in Data.Type.Witness.Specific.Symbol

Methods

testCompare :: forall (a :: Symbol) (b :: Symbol). SymbolType a -> SymbolType b -> WOrdering a b Source #

TestOrder (EmptyType :: k -> Type) Source # 
Instance details

Defined in Data.Type.Witness.Specific.Empty

Methods

testCompare :: forall (a :: k) (b :: k). EmptyType a -> EmptyType b -> WOrdering a b Source #

TestOrder (ListElementType tt :: k -> Type) Source # 
Instance details

Defined in Data.Type.Witness.Specific.List.Element

Methods

testCompare :: forall (a :: k) (b :: k). ListElementType tt a -> ListElementType tt b -> WOrdering a b Source #

TestOrder w1 => TestOrder (PairType w1 w2 :: k -> Type) Source #

left-biased

Instance details

Defined in Data.Type.Witness.Specific.Pair

Methods

testCompare :: forall (a :: k) (b :: k). PairType w1 w2 a -> PairType w1 w2 b -> WOrdering a b Source #