compdata-0.13.1: Compositional Data Types
Copyright(c) 2010-2011 Patrick Bahr
LicenseBSD3
MaintainerPatrick Bahr <paba@diku.dk>
Stabilityexperimental
Portabilitynon-portable (GHC Extensions)
Safe HaskellSafe-Inferred
LanguageHaskell2010

Data.Comp.Equality

Description

This module defines equality for signatures, which lifts to equality for terms and contexts.

Synopsis

Documentation

class EqF f where Source #

Signature equality. An instance EqF f gives rise to an instance Eq (Term f).

Methods

eqF :: Eq a => f a -> f a -> Bool Source #

Instances

Instances details
EqF Maybe Source # 
Instance details

Defined in Data.Comp.Equality

Methods

eqF :: Eq a => Maybe a -> Maybe a -> Bool Source #

EqF [] Source # 
Instance details

Defined in Data.Comp.Equality

Methods

eqF :: Eq a => [a] -> [a] -> Bool Source #

Eq a => EqF ((,) a) Source # 
Instance details

Defined in Data.Comp.Equality

Methods

eqF :: Eq a0 => (a, a0) -> (a, a0) -> Bool Source #

EqF f => EqF (Cxt h f) Source # 
Instance details

Defined in Data.Comp.Equality

Methods

eqF :: Eq a => Cxt h f a -> Cxt h f a -> Bool Source #

(Eq a, Eq b) => EqF ((,,) a b) Source # 
Instance details

Defined in Data.Comp.Equality

Methods

eqF :: Eq a0 => (a, b, a0) -> (a, b, a0) -> Bool Source #

(EqF f, EqF g) => EqF (f :+: g) Source #

EqF is propagated through sums.

Instance details

Defined in Data.Comp.Equality

Methods

eqF :: Eq a => (f :+: g) a -> (f :+: g) a -> Bool Source #

(Eq a, Eq b, Eq c) => EqF ((,,,) a b c) Source # 
Instance details

Defined in Data.Comp.Equality

Methods

eqF :: Eq a0 => (a, b, c, a0) -> (a, b, c, a0) -> Bool Source #

(Eq a, Eq b, Eq c, Eq d) => EqF ((,,,,) a b c d) Source # 
Instance details

Defined in Data.Comp.Equality

Methods

eqF :: Eq a0 => (a, b, c, d, a0) -> (a, b, c, d, a0) -> Bool Source #

(Eq a, Eq b, Eq c, Eq d, Eq e) => EqF ((,,,,,) a b c d e) Source # 
Instance details

Defined in Data.Comp.Equality

Methods

eqF :: Eq a0 => (a, b, c, d, e, a0) -> (a, b, c, d, e, a0) -> Bool Source #

(Eq a, Eq b, Eq c, Eq d, Eq e, Eq f) => EqF ((,,,,,,) a b c d e f) Source # 
Instance details

Defined in Data.Comp.Equality

Methods

eqF :: Eq a0 => (a, b, c, d, e, f, a0) -> (a, b, c, d, e, f, a0) -> Bool Source #

(Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g) => EqF ((,,,,,,,) a b c d e f g) Source # 
Instance details

Defined in Data.Comp.Equality

Methods

eqF :: Eq a0 => (a, b, c, d, e, f, g, a0) -> (a, b, c, d, e, f, g, a0) -> Bool Source #

(Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h) => EqF ((,,,,,,,,) a b c d e f g h) Source # 
Instance details

Defined in Data.Comp.Equality

Methods

eqF :: Eq a0 => (a, b, c, d, e, f, g, h, a0) -> (a, b, c, d, e, f, g, h, a0) -> Bool Source #

(Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i) => EqF ((,,,,,,,,,) a b c d e f g h i) Source # 
Instance details

Defined in Data.Comp.Equality

Methods

eqF :: Eq a0 => (a, b, c, d, e, f, g, h, i, a0) -> (a, b, c, d, e, f, g, h, i, a0) -> Bool Source #

eqMod :: (EqF f, Functor f, Foldable f) => f a -> f b -> Maybe [(a, b)] Source #

This function implements equality of values of type f a modulo the equality of a itself. If two functorial values are equal in this sense, eqMod returns a Just value containing a list of pairs consisting of corresponding components of the two functorial values.

Orphan instances

EqF Maybe Source # 
Instance details

Methods

eqF :: Eq a => Maybe a -> Maybe a -> Bool Source #

EqF [] Source # 
Instance details

Methods

eqF :: Eq a => [a] -> [a] -> Bool Source #

Eq a => EqF ((,) a) Source # 
Instance details

Methods

eqF :: Eq a0 => (a, a0) -> (a, a0) -> Bool Source #

EqF f => EqF (Cxt h f) Source # 
Instance details

Methods

eqF :: Eq a => Cxt h f a -> Cxt h f a -> Bool Source #

(Eq a, Eq b) => EqF ((,,) a b) Source # 
Instance details

Methods

eqF :: Eq a0 => (a, b, a0) -> (a, b, a0) -> Bool Source #

(EqF f, EqF g) => EqF (f :+: g) Source #

EqF is propagated through sums.

Instance details

Methods

eqF :: Eq a => (f :+: g) a -> (f :+: g) a -> Bool Source #

(Eq a, Eq b, Eq c) => EqF ((,,,) a b c) Source # 
Instance details

Methods

eqF :: Eq a0 => (a, b, c, a0) -> (a, b, c, a0) -> Bool Source #

(EqF f, Eq a) => Eq (Cxt h f a) Source #

From an EqF functor an Eq instance of the corresponding term type can be derived.

Instance details

Methods

(==) :: Cxt h f a -> Cxt h f a -> Bool #

(/=) :: Cxt h f a -> Cxt h f a -> Bool #

(Eq a, Eq b, Eq c, Eq d) => EqF ((,,,,) a b c d) Source # 
Instance details

Methods

eqF :: Eq a0 => (a, b, c, d, a0) -> (a, b, c, d, a0) -> Bool Source #

(Eq a, Eq b, Eq c, Eq d, Eq e) => EqF ((,,,,,) a b c d e) Source # 
Instance details

Methods

eqF :: Eq a0 => (a, b, c, d, e, a0) -> (a, b, c, d, e, a0) -> Bool Source #

(Eq a, Eq b, Eq c, Eq d, Eq e, Eq f) => EqF ((,,,,,,) a b c d e f) Source # 
Instance details

Methods

eqF :: Eq a0 => (a, b, c, d, e, f, a0) -> (a, b, c, d, e, f, a0) -> Bool Source #

(Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g) => EqF ((,,,,,,,) a b c d e f g) Source # 
Instance details

Methods

eqF :: Eq a0 => (a, b, c, d, e, f, g, a0) -> (a, b, c, d, e, f, g, a0) -> Bool Source #

(Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h) => EqF ((,,,,,,,,) a b c d e f g h) Source # 
Instance details

Methods

eqF :: Eq a0 => (a, b, c, d, e, f, g, h, a0) -> (a, b, c, d, e, f, g, h, a0) -> Bool Source #

(Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i) => EqF ((,,,,,,,,,) a b c d e f g h i) Source # 
Instance details

Methods

eqF :: Eq a0 => (a, b, c, d, e, f, g, h, i, a0) -> (a, b, c, d, e, f, g, h, i, a0) -> Bool Source #