[commit: haddock] T6018-injective-type-families, adamse-D1033, ghc-head, master, metainfo, wip/10268, wip/10313, wip/D538, wip/D538-1, wip/D538-2, wip/D538-3, wip/D538-4, wip/D538-5, wip/D538-6, wip/D548-master, wip/D548-master-2, wip/T10483, wip/T9840, wip/api-annot-tweaks-7.10, wip/api-annots-ghc-7.10-3, wip/orf-reboot: Derive more instances (1c5f4fe)

git at git.haskell.org git at git.haskell.org
Wed Jul 8 08:32:15 UTC 2015


Repository : ssh://git@git.haskell.org/haddock

On branches: T6018-injective-type-families,adamse-D1033,ghc-head,master,metainfo,wip/10268,wip/10313,wip/D538,wip/D538-1,wip/D538-2,wip/D538-3,wip/D538-4,wip/D538-5,wip/D538-6,wip/D548-master,wip/D548-master-2,wip/T10483,wip/T9840,wip/api-annot-tweaks-7.10,wip/api-annots-ghc-7.10-3,wip/orf-reboot
Link       : http://git.haskell.org/haddock.git/commitdiff/1c5f4fe3c4e3ef73481855a51af73d8995450e30

>---------------------------------------------------------------

commit 1c5f4fe3c4e3ef73481855a51af73d8995450e30
Author: Simon Hengel <sol at typeful.net>
Date:   Sun Nov 2 09:30:38 2014 +0800

    Derive more instances


>---------------------------------------------------------------

1c5f4fe3c4e3ef73481855a51af73d8995450e30
 haddock-library/src/Documentation/Haddock/Types.hs | 9 +--------
 1 file changed, 1 insertion(+), 8 deletions(-)

diff --git a/haddock-library/src/Documentation/Haddock/Types.hs b/haddock-library/src/Documentation/Haddock/Types.hs
index 9a64fb6..b2d28be 100644
--- a/haddock-library/src/Documentation/Haddock/Types.hs
+++ b/haddock-library/src/Documentation/Haddock/Types.hs
@@ -17,18 +17,11 @@ module Documentation.Haddock.Types where
 import Data.Foldable
 import Data.Traversable
 
-instance Foldable Header where
-  foldMap f (Header _ a) = f a
-
-instance Traversable Header where
-  traverse f (Header l a) = Header l `fmap` f a
-
 data Hyperlink = Hyperlink
   { hyperlinkUrl   :: String
   , hyperlinkLabel :: Maybe String
   } deriving (Eq, Show)
 
-
 data Picture = Picture
   { pictureUri   :: String
   , pictureTitle :: Maybe String
@@ -37,7 +30,7 @@ data Picture = Picture
 data Header id = Header
   { headerLevel :: Int
   , headerTitle :: id
-  } deriving (Eq, Show, Functor)
+  } deriving (Eq, Show, Functor, Foldable, Traversable)
 
 data Example = Example
   { exampleExpression :: String



More information about the ghc-commits mailing list