groupoid-0.1.0: A Groupoid class

PortabilityFlexibleInstances
Stabilityexperimental
Maintainerstephen.tetley@gmail.com

Data.Groupoid

Contents

Description

Groupoid - a set with a binary operator, more general than monoid as there is no obligation to have a neutral element (i.e mempty in Data.Monoid).

Synopsis

Groupoid typeclass

class Groupoid a whereSource

Methods

gappend :: a -> a -> aSource

A binary operation, not necessarily associative.

gconcat :: [a] -> aSource

Fold a non-empty list with the groupoid. The default definition uses foldr1 which throws an exception when applied to the empty list.

Instances

Groupoid Ordering 
Groupoid () 
Groupoid All 
Groupoid Any 
Groupoid [a] 
Groupoid a => Groupoid (Dual a) 
Groupoid (Endo a) 
Num a => Groupoid (Sum a) 
Num a => Groupoid (Product a) 
Groupoid (First a) 
Groupoid (Last a) 
Groupoid a => Groupoid (Maybe a) 
Groupoid (a -> a) 
(Groupoid a, Groupoid b) => Groupoid (a, b) 
(Groupoid a, Groupoid b, Groupoid c) => Groupoid (a, b, c) 
(Groupoid a, Groupoid b, Groupoid c, Groupoid d) => Groupoid (a, b, c, d) 
(Groupoid a, Groupoid b, Groupoid c, Groupoid d, Groupoid e) => Groupoid (a, b, c, d, e)