bifunctors-5.1: Bifunctors

Copyright | (C) 2008-2015 Edward Kmett
License | BSD-style (see the file LICENSE)
Maintainer | Edward Kmett <ekmett@gmail.com>
Stability | provisional
Portability | portable
Safe Haskell | Safe
Language | Haskell98

Data.Bifunctor.Joker

Description

From the Functional Pearl "Clowns to the Left of me, Jokers to the Right: Dissecting Data Structures" by Conor McBride.

Synopsis

- newtype Joker g a b = Joker {
  - runJoker :: g b
  }

# Documentation

newtype Joker g a b Source

Make a `Functor` over the second argument of a `Bifunctor`.

Mnemonic: Clowns to the left (parameter of the Bifunctor), jokers to the right.

Constructors

Joker |

Fields

runJoker :: g b

Instances

Functor g => Bifunctor (Joker g) Source |
Foldable g => Bifoldable (Joker g) Source |
Traversable g => Bitraversable (Joker g) Source |
Applicative g => Biapplicative (Joker g) Source |
Functor g => Functor (Joker g a) Source |
Foldable g => Foldable (Joker g a) Source |
Traversable g => Traversable (Joker g a) Source |
Eq (g b) => Eq (Joker g a b) Source |
Ord (g b) => Ord (Joker g a b) Source |
Read (g b) => Read (Joker g a b) Source |
Show (g b) => Show (Joker g a b) Source |