Safe Haskell | Safe |
---|---|
Language | GHC2021 |
LambdaUC.Types
Synopsis
- module Data.HList
- data Void
- type Type = TYPE LiftedRep
- type Constraint = CONSTRAINT LiftedRep
- data (a :: k) :~: (b :: k) where
- type Continuation x = forall a. (x -> a) -> a
- type Not (a :: Type) = a -> Void
- data SBool (a :: Bool) where
- data SIndex (a :: Index) where
- type family Or x y where ...
- type family BoolNeg x where ...
- class Empty x
- type family IfThenElse c t f where ...
- class KnownBool (b :: Bool) where
- lemmaBoolNegInv :: forall b. KnownBool b => BoolNeg (BoolNeg b) :~: b
- class KnownIndex (b :: Index) where
- data KnownLenD :: forall a. [a] -> Type where
- class KnownLen l where
- getKnownLenPrf :: KnownLenD l
- data SameLenD :: forall a b. [a] -> [b] -> Type where
- SameLenNil :: SameLenD '[] '[]
- SameLenCons :: SameLenD l l' -> SameLenD (x : l) (x' : l')
- class SameLen l l' where
- proveSameLength :: SameLenD l l'
- data Index
Documentation
module Data.HList
Uninhabited data type
Since: base-4.8.0.0
Instances
Semigroup Void | Since: base-4.9.0.0 |
Generic Void | |
Read Void | Reading a Since: base-4.8.0.0 |
Show Void | Since: base-4.8.0.0 |
Eq Void | Since: base-4.8.0.0 |
Ord Void | Since: base-4.8.0.0 |
Hashable Void | |
Defined in Data.Hashable.Class | |
MayOnlyReturnAfterRecv 'NextRecv Void # | |
Defined in LambdaUC.Syntax.Async.Eval.Internal Methods getMayOnlyReturnAfterRecvPrf :: MayOnlyReturnAfterRecvD 'NextRecv Void # | |
type Rep Void | Since: base-4.8.0.0 |
type Constraint = CONSTRAINT LiftedRep #
The kind of lifted constraints
data (a :: k) :~: (b :: k) where infix 4 #
Propositional equality. If a :~: b
is inhabited by some terminating
value, then the type a
is the same as the type b
. To use this equality
in practice, pattern-match on the a :~: b
to get out the Refl
constructor;
in the body of the pattern-match, the compiler knows that a ~ b
.
Since: base-4.7.0.0
Instances
Category ((:~:) :: k -> k -> Type) | Since: base-4.7.0.0 |
TestEquality ((:~:) a :: k -> Type) | Since: base-4.7.0.0 |
Defined in Data.Type.Equality | |
a ~ b => Bounded (a :~: b) | Since: base-4.7.0.0 |
a ~ b => Enum (a :~: b) | Since: base-4.7.0.0 |
Defined in Data.Type.Equality Methods succ :: (a :~: b) -> a :~: b # pred :: (a :~: b) -> a :~: b # fromEnum :: (a :~: b) -> Int # enumFrom :: (a :~: b) -> [a :~: b] # enumFromThen :: (a :~: b) -> (a :~: b) -> [a :~: b] # enumFromTo :: (a :~: b) -> (a :~: b) -> [a :~: b] # enumFromThenTo :: (a :~: b) -> (a :~: b) -> (a :~: b) -> [a :~: b] # | |
a ~ b => Read (a :~: b) | Since: base-4.7.0.0 |
Show (a :~: b) | Since: base-4.7.0.0 |
Eq (a :~: b) | Since: base-4.7.0.0 |
Ord (a :~: b) | Since: base-4.7.0.0 |
Defined in Data.Type.Equality |
type Continuation x = forall a. (x -> a) -> a #
type family IfThenElse c t f where ... #
Type-level if-then-else, we use it to choose constraints conditionally
Equations
IfThenElse True t _ = t | |
IfThenElse False _ f = f |
class KnownBool (b :: Bool) where #
Known boolean value. Implemented by constants, but not by `forall (b ::
Bool). b`. Adding this to the context of a function polymorphic over b
is
the same as adding an explicit parameter `SBool b` to it. I.e. `SBool b ->`
is the same as `KnownBool b =>`.
class KnownIndex (b :: Index) where #
Instances
KnownIndex 'NextRecv # | |
Defined in LambdaUC.Types | |
KnownIndex 'NextSend # | |
Defined in LambdaUC.Types |
data KnownLenD :: forall a. [a] -> Type where #
Signleton type to express the list structure (length) but not the contents.
Class of list values for which their length is known at compile time.
Methods
getKnownLenPrf :: KnownLenD l #
Instances
KnownLen ('[] :: [a]) # | |
Defined in Data.HList Methods getKnownLenPrf :: KnownLenD '[] # | |
KnownLen xs => KnownLen (x ': xs :: [a]) # | |
Defined in Data.HList Methods getKnownLenPrf :: KnownLenD (x ': xs) # |
data SameLenD :: forall a b. [a] -> [b] -> Type where #
Constructors
SameLenNil :: SameLenD '[] '[] | |
SameLenCons :: SameLenD l l' -> SameLenD (x : l) (x' : l') |
Methods
proveSameLength :: SameLenD l l' #
Instances
SameLen ('[] :: [a]) ('[] :: [b]) # | |
Defined in Data.HList Methods proveSameLength :: SameLenD '[] '[] # | |
SameLen l l' => SameLen (x ': l :: [a]) (x' ': l' :: [b]) # | |
Defined in Data.HList Methods proveSameLength :: SameLenD (x ': l) (x' ': l') # |
Next operation of the asyncronous algorithm
Instances
XApplicative (AsyncExT ex ports :: Index -> Index -> Type -> Type) # | |
Defined in LambdaUC.Syntax.Async Methods xpure :: forall a (p :: k). a -> AsyncExT ex ports p p a # (<*>:) :: forall (p :: k) (q :: k) a b (r :: k). AsyncExT ex ports p q (a -> b) -> AsyncExT ex ports q r a -> AsyncExT ex ports p r b # xliftA2 :: forall a b c (p :: k) (q :: k) (r :: k). (a -> b -> c) -> AsyncExT ex ports p q a -> AsyncExT ex ports q r b -> AsyncExT ex ports p r c # (*>:) :: forall (p :: k) (q :: k) a (r :: k) b. AsyncExT ex ports p q a -> AsyncExT ex ports q r b -> AsyncExT ex ports p r b # (<*:) :: forall (p :: k) (q :: k) a (r :: k) b. AsyncExT ex ports p q a -> AsyncExT ex ports q r b -> AsyncExT ex ports p r a # | |
XMonad (AsyncExT ex ports :: Index -> Index -> Type -> Type) # | |
Defined in LambdaUC.Syntax.Async Methods (>>=:) :: forall a b (p :: k) (q :: k) (r :: k). AsyncExT ex ports p q a -> (a -> AsyncExT ex ports q r b) -> AsyncExT ex ports p r b # (>>:) :: forall a b (p :: k) (q :: k) (r :: k). AsyncExT ex ports p q a -> AsyncExT ex ports q r b -> AsyncExT ex ports p r b # xreturn :: forall a (p :: k). a -> AsyncExT ex ports p p a # |