free-4.12.1: Monads for free

Copyright | (C) 2008-2011 Edward Kmett
License | BSD-style (see the file LICENSE)
Maintainer | Edward Kmett <ekmett@gmail.com>
Stability | experimental
Portability | fundeps, MPTCs
Safe Haskell | Safe
Language | Haskell2010

Control.Comonad.Cofree.Class

Description

Synopsis

- class (Functor f, Comonad w) => ComonadCofree f w | w -> f where
  - unwrap :: w a -> f (w a)

# Documentation

class (Functor f, Comonad w) => ComonadCofree f w | w -> f where Source

Allows you to peel a layer off a cofree comonad.

Methods

unwrap :: w a -> f (w a) Source

Remove a layer.

Instances

ComonadCofree Maybe NonEmpty Source |
ComonadCofree f w => ComonadCofree f (IdentityT w) Source |
Functor f => ComonadCofree f (Cofree f) Source |
Comonad w => ComonadCofree Identity (CoiterT w) Source |
(ComonadCofree f w, Semigroup m, Monoid m) => ComonadCofree f (TracedT m w) Source |
ComonadCofree f w => ComonadCofree f (StoreT s w) Source |
ComonadCofree f w => ComonadCofree f (EnvT e w) Source |
(Functor f, Comonad w) => ComonadCofree f (CofreeT f w) Source |
ComonadCofree (Const b) ((,) b) Source |