add derived instances for Dual monoid
authorRoss Paterson <ross@soi.city.ac.uk>
Fri, 2 Feb 2007 19:08:47 +0000 (19:08 +0000)
committerRoss Paterson <ross@soi.city.ac.uk>
Fri, 2 Feb 2007 19:08:47 +0000 (19:08 +0000)
Data/Monoid.hs

index 8a30b73..c51c4ca 100644 (file)
@@ -97,6 +97,7 @@ instance Monoid Ordering where
 
 -- | The dual of a monoid, obtained by swapping the arguments of 'mappend'.
 newtype Dual a = Dual { getDual :: a }
+       deriving (Eq, Ord, Read, Show, Bounded)
 
 instance Monoid a => Monoid (Dual a) where
        mempty = Dual mempty