diff options
author | RyanGlScott <ryan.gl.scott@gmail.com> | 2016-02-11 20:17:09 -0500 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2016-04-16 17:58:06 +0200 |
commit | 82f5ef8484fb91230a83d26c971a7082547e32b8 (patch) | |
tree | 079683cc3d4c7fba04728320ec82ee65353d5789 /haddock-api/src/Haddock/Backends | |
parent | 035f2f18448d6f81a16d80e8b2ae8025616f8d41 (diff) |
Ensure expanded family instances render correctly
(cherry picked from commit 1338b5d7c32939de6bbc31af0049477e4f847103)
Diffstat (limited to 'haddock-api/src/Haddock/Backends')
-rw-r--r-- | haddock-api/src/Haddock/Backends/Xhtml/Decl.hs | 5 | ||||
-rw-r--r-- | haddock-api/src/Haddock/Backends/Xhtml/Layout.hs | 2 |
2 files changed, 4 insertions, 3 deletions
diff --git a/haddock-api/src/Haddock/Backends/Xhtml/Decl.hs b/haddock-api/src/Haddock/Backends/Xhtml/Decl.hs index 660a8475..fab6bf8d 100644 --- a/haddock-api/src/Haddock/Backends/Xhtml/Decl.hs +++ b/haddock-api/src/Haddock/Backends/Xhtml/Decl.hs @@ -616,14 +616,15 @@ ppInstHead links splice unicode qual mdoc origin orphan no ihd@(InstHead {..}) = ) where ptype = keyword "type" <+> typ - prhs = maybe noHtml (\t -> equals <+> ppType unicode qual t) rhs + prhs = ptype <+> maybe noHtml + (\t -> equals <+> ppType unicode qual t) rhs DataInst dd -> ( subInstHead iid pdata , mdoc , [subFamInstDetails iid pdecl]) where pdata = keyword "data" <+> typ - pdecl = ppShortDataDecl False True dd unicode qual + pdecl = pdata <+> ppShortDataDecl False True dd unicode qual where iid = instanceId origin no orphan ihd typ = ppAppNameTypes ihdClsName ihdKinds ihdTypes unicode qual diff --git a/haddock-api/src/Haddock/Backends/Xhtml/Layout.hs b/haddock-api/src/Haddock/Backends/Xhtml/Layout.hs index 19de935c..41457f72 100644 --- a/haddock-api/src/Haddock/Backends/Xhtml/Layout.hs +++ b/haddock-api/src/Haddock/Backends/Xhtml/Layout.hs @@ -232,7 +232,7 @@ subFamInstDetails :: String -- ^ Instance unique id (for anchor generation) -> Html -- ^ Type or data family instance -> Html subFamInstDetails iid fi = - subInstSection iid << declElem fi + subInstSection iid << thediv ! [theclass "src"] << fi subInstSection :: String -- ^ Instance unique id (for anchor generation) -> Html |