From b421d12bf0e3e76e618b2b45ccb57cce4666ca24 Mon Sep 17 00:00:00 2001 From: Kailuo Wang Date: Tue, 21 Mar 2017 15:46:42 -0400 Subject: [PATCH] added more typeclasses to the diagram --- docs/src/main/tut/typeclasses/typeclasses.md | 34 +++++++++++++++----- 1 file changed, 26 insertions(+), 8 deletions(-) diff --git a/docs/src/main/tut/typeclasses/typeclasses.md b/docs/src/main/tut/typeclasses/typeclasses.md index 06b351c76b..10a2eea1e7 100644 --- a/docs/src/main/tut/typeclasses/typeclasses.md +++ b/docs/src/main/tut/typeclasses/typeclasses.md @@ -227,27 +227,40 @@ type class instances easy. size ="6,6"; edge [dir=back] node [shape=box,style="rounded"] + FunctorFilter [group=g8] + TraverseFilter [group=g8] + Traverse [group=g8] + Foldable [group=g9] + Reducible [group=g9] Functor [group=g2] Apply [group=g2] Applicative [group=g2] Monad [group=g2] - SemigroupK [group=g1] - MonoidK [group=g1] - Alternative [group=g1] - MonadFilter [group=g1] - MonadCombine [group=g1] + SemigroupK [group=g3] + MonoidK [group=g3] Invariant [group=g4] Contravariant [group=g4] CoflatMap [group=g5] Comonad [group=g5] - Bimonad [group=g5] MonadError [group=g6] ApplicativeError [group=g6] + Bitraverse [group=g7] + Bifoldable [group=g7] + Bifunctor [group=g7] Functor -> Apply -> Applicative -> Monad -> MonadFilter -> MonadCombine + subgraph cluster_s4 { + Bifoldable -> Bitraverse + Bifunctor -> Bitraverse + graph[style=dotted] + } + subgraph cluster_s5 { + ApplicativeError -> MonadError + graph[style=dotted] + } Applicative -> Alternative -> MonadCombine MonoidK -> Alternative Functor -> CoflatMap - Applicative -> ApplicativeError -> MonadError + Applicative -> ApplicativeError Monad -> MonadError subgraph cluster_s3{ Invariant -> Contravariant @@ -259,13 +272,18 @@ type class instances easy. graph[style=dotted] } subgraph cluster_s1{ - CoflatMap -> Comonad -> Bimonad + CoflatMap -> Comonad graph[style=dotted] } + Comonad -> Bimonad Monad -> Bimonad Apply -> FlatMap -> Monad Foldable -> Traverse Functor -> Traverse + Traverse -> TraverseFilter + FunctorFilter -> TraverseFilter + FunctorFilter -> MonadFilter + Functor -> FunctorFilter Foldable -> Reducible } )