Copyright | (C) 2013 Richard Eisenberg |
---|---|
License | BSD-style (see LICENSE) |
Maintainer | Richard Eisenberg (eir@cis.upenn.edu) |
Stability | experimental |
Portability | non-portable |
Safe Haskell | None |
Language | Haskell2010 |
Defines functions and datatypes relating to the singleton for tuples,
including a singletons version of all the definitions in Data.Tuple
.
Because many of these definitions are produced by Template Haskell,
it is not possible to create proper Haddock documentation. Please look
up the corresponding operation in Data.Tuple
. Also, please excuse
the apparent repeated variable names. This is due to an interaction
between Template Haskell and Haddock.
- data family Sing a
- type STuple0 z = Sing z
- type STuple2 z = Sing z
- type STuple3 z = Sing z
- type STuple4 z = Sing z
- type STuple5 z = Sing z
- type STuple6 z = Sing z
- type STuple7 z = Sing z
- type family Fst a :: a
- sFst :: forall t. Sing t -> Sing (Fst t)
- type family Snd a :: b
- sSnd :: forall t. Sing t -> Sing (Snd t)
- type family Curry a a a :: c
- sCurry :: forall t t t. (forall t. Sing t -> Sing (t t)) -> Sing t -> Sing t -> Sing (Curry t t t)
- type family Uncurry a a :: c
- sUncurry :: forall t t. (forall t. Sing t -> forall t. Sing t -> Sing (t t t)) -> Sing t -> Sing (Uncurry t t)
- type family Swap a :: (b, a)
- sSwap :: forall t. Sing t -> Sing (Swap t)
Singleton definitions
See Sing
for more info.
The singleton kind-indexed data family.
TestCoercion * (Sing *) | |
SDecide k (KProxy k) => TestEquality k (Sing k) | |
data Sing Bool where | |
data Sing Ordering where | |
data Sing * where | |
data Sing Nat where | |
data Sing Symbol where
| |
data Sing () where | |
data Sing [a0] where | |
data Sing (Maybe a0) where | |
data Sing (Either a0 b0) where | |
data Sing ((,) a0 b0) where | |
data Sing ((,,) a0 b0 c0) where | |
data Sing ((,,,) a0 b0 c0 d0) where | |
data Sing ((,,,,) a0 b0 c0 d0 e0) where | |
data Sing ((,,,,,) a0 b0 c0 d0 e0 f0) where | |
data Sing ((,,,,,,) a0 b0 c0 d0 e0 f0 g0) where |
Singletons from Data.Tuple
sCurry :: forall t t t. (forall t. Sing t -> Sing (t t)) -> Sing t -> Sing t -> Sing (Curry t t t) Source