plutus-tx
Safe HaskellNone
LanguageHaskell2010

PlutusTx.Blueprint.Definition.TF

Synopsis
  • type family IfStuckUnroll (e :: [Type]) (t :: [Type]) :: [Type] where ...
  • type family IfStuckRep (e :: Type -> Type) (rep :: Type -> Type) :: Type -> Type where ...
  • type family Insert (x :: k) (xs :: [k]) :: [k] where ...
  • type family Concat (as :: [k]) (bs :: [k]) :: [k] where ...
  • type family (as :: [k]) ++ (bs :: [k]) :: [k] where ...
  • type family Reverse (xs :: [k]) :: [k] where ...
  • type family Append (xs :: [k]) (ys :: [k]) :: [k] where ...
  • type family Nub (xs :: [k]) :: [k] where ...
  • type family NubHelper (acc :: [k]) (xs :: [k]) :: [k] where ...

Documentation

type family IfStuckUnroll (e :: [Type]) (t :: [Type]) :: [Type] where ... Source #

Equations

IfStuckUnroll _1 ('[] :: [Type]) = '[] :: [Type] 
IfStuckUnroll _1 (x ': xs) = x ': xs 
IfStuckUnroll e _1 = e 

type family IfStuckRep (e :: Type -> Type) (rep :: Type -> Type) :: Type -> Type where ... Source #

Equations

IfStuckRep _1 (M1 a b c) = M1 a b c 
IfStuckRep _1 (f :*: g) = f :*: g 
IfStuckRep _1 (f :+: g) = f :+: g 
IfStuckRep _1 (K1 a b :: Type -> Type) = K1 a b :: Type -> Type 
IfStuckRep e (U1 :: Type -> Type) = U1 :: Type -> Type 
IfStuckRep e x = e 

type family Insert (x :: k) (xs :: [k]) :: [k] where ... Source #

Insert x into xs unless it's already there.

Equations

Insert (x :: k) ('[] :: [k]) = '[x] 
Insert (x :: a) (x ': xs :: [a]) = x ': xs 
Insert (x :: k) (y ': xs :: [k]) = y ': Insert x xs 

type family Concat (as :: [k]) (bs :: [k]) :: [k] where ... Source #

Concatenates two type-level lists

Equations

Concat ('[] :: [k]) (bs :: [k]) = bs 
Concat (as :: [k]) ('[] :: [k]) = as 
Concat (a ': as :: [k]) (bs :: [k]) = a ': Concat as bs 

type family (as :: [k]) ++ (bs :: [k]) :: [k] where ... infixr 5 Source #

Concatenates two type-level lists removing duplicates.

Equations

('[] :: [k]) ++ (bs :: [k]) = bs 
(as :: [k]) ++ ('[] :: [k]) = as 
(a ': as :: [k]) ++ (bs :: [k]) = Insert a (as ++ bs) 

type family Reverse (xs :: [k]) :: [k] where ... Source #

Equations

Reverse ('[] :: [k]) = '[] :: [k] 
Reverse (x ': xs :: [k]) = Append (Reverse xs) '[x] 

type family Append (xs :: [k]) (ys :: [k]) :: [k] where ... Source #

Equations

Append ('[] :: [k]) (ys :: [k]) = ys 
Append (x ': xs :: [k]) (ys :: [k]) = x ': Append xs ys 

type family Nub (xs :: [k]) :: [k] where ... Source #

Equations

Nub (xs :: [k]) = NubHelper ('[] :: [k]) xs 

type family NubHelper (acc :: [k]) (xs :: [k]) :: [k] where ... Source #

Equations

NubHelper (acc :: [k]) ('[] :: [k]) = acc 
NubHelper (acc :: [k]) (x ': xs :: [k]) = NubHelper (Insert x acc) xs