Copyright | Copyright (C) 2015 Kyle Carter |
---|---|
License | BSD3 |
Maintainer | Kyle Carter <kylcarte@indiana.edu> |
Stability | experimental |
Portability | RankNTypes |
Safe Haskell | Safe |
Language | Haskell2010 |
Type-level Monoid
, defined as an open type family.
Documentation
type family Mempty :: k Source
type Mempty [k] = Ø k Source | |
type Mempty (Maybe k) = Nothing k Source | |
type Mempty (Either k k1) = Left k k1 (Mempty k) Source | |
type Mempty ((,) k k1) = (#) k k1 (Mempty k) (Mempty k1) Source | A type-level pair is a Monoid over its pairwise components. |
type Mempty ((,,) k k1 k2) = (,,) k k1 k2 (Mempty k) (Mempty k1) (Mempty k2) Source |
type family a <> b :: k Source
type (<>) [k] a b = (++) k a b Source | |
type (<>) (Maybe k) a b = (<|>) k a b Source | |
type (<>) (Either k k1) a b = (<|>) k k1 a b Source | |
type (<>) ((,) k k1) ((#) k k1 r a) ((#) k k1 s b) = (#) k k1 ((<>) k r s) ((<>) k1 a b) Source | |
type (<>) ((,,) k k1 k2) ((,,) k k1 k2 a b c) ((,,) k k1 k2 d e f) = (,,) k k1 k2 ((<>) k a d) ((<>) k1 b e) ((<>) k2 c f) Source |