packages feed

thrist 0.0 → 0.1

raw patch · 2 files changed

+19/−4 lines, 2 files

Files

Data/Thrist.hs view
@@ -1,7 +1,9 @@-module Data.Thrist( Thrist(..)-                  , foldThrist ) where+module Data.Thrist ( Thrist (..)+                   , foldThrist+                   , appendThrist ) where  import Prelude+import Data.Monoid -- import Data.Char  data Thrist :: (* -> * -> *) -> * -> * -> * where@@ -19,4 +21,17 @@ t2 :: Char -> Char t2 = foldThrist (flip (.)) id t1 -}++appendThrist :: forall (p :: * -> * -> *) a b c .+                Thrist p a b ->+                Thrist p b c ->+                Thrist p a c++appendThrist Nil a = a+appendThrist (Cons b r) a = Cons b (appendThrist r a)+++instance Monoid (Thrist p a a) where+  mempty = Nil+  mappend = appendThrist 
thrist.cabal view
@@ -1,5 +1,5 @@ Name:                thrist-Version:             0.0+Version:             0.1 Synopsis:            Type-threaded list  Description:@@ -30,7 +30,7 @@  Stability:           experimental Build-Depends:       base-Extensions:          GADTs+Extensions:          GADTs, RankNTypes, KindSignatures, FlexibleInstances  Exposed-Modules:     Data.Thrist Ghc-Options:         -Wall