invertible-0.1: bidirectional arrows, bijective functions, and invariant functors

Safe HaskellSafe
LanguageHaskell2010

Control.Invertible.Functor

Description

This provides a subset of the functionality as the invariant package's Data.Functor.Invariant module, but based on Data.Invertible, without all the instances, and with an interface matching Data.Functor.

This module is intended to be imported qualified, e.g.,:

import qualified Control.Invertible.Functor as Inv

Synopsis

Documentation

class Functor f where Source

An invariant version of Functor, equivalent to Invariant.

Methods

fmap :: (a <-> b) -> f a -> f b Source

(<$>) :: Functor f => (a <-> b) -> f a -> f b infixl 4 Source

An infix synnonym for fmap.