aboutsummaryrefslogtreecommitdiff
path: root/src/Haddock/Backends/LaTeX.hs
diff options
context:
space:
mode:
authorNiklas Haas <git@nand.wakku.to>2014-03-12 10:31:31 +0100
committerMateusz Kowalczyk <fuuzetsu@fuuzetsu.co.uk>2014-03-13 19:18:06 +0000
commit3606ad5fdb8b9c2c3f9a62de1d26702ad41f9a10 (patch)
tree56e35153453b6469ef34cd356b966293ee81d1ff /src/Haddock/Backends/LaTeX.hs
parent8f71c6f26eb5b36e5a1ca253b8c8ffdca75849d8 (diff)
Hide RHS of TFs with non-exported right hand sides
Not sure what to do about data families yet, since technically it would not make a lot of sense to display constructors that cannot be used by the user.
Diffstat (limited to 'src/Haddock/Backends/LaTeX.hs')
-rw-r--r--src/Haddock/Backends/LaTeX.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Haddock/Backends/LaTeX.hs b/src/Haddock/Backends/LaTeX.hs
index 6535b24e..44b3fc35 100644
--- a/src/Haddock/Backends/LaTeX.hs
+++ b/src/Haddock/Backends/LaTeX.hs
@@ -563,7 +563,8 @@ ppInstDecl unicode instHead = keyword "instance" <+> ppInstHead unicode instHead
ppInstHead :: Bool -> InstHead DocName -> LaTeX
ppInstHead unicode (n, ks, ts, ClassInst ctx) = ppContextNoLocs ctx unicode <+> ppAppNameTypes n ks ts unicode
ppInstHead unicode (n, ks, ts, TypeInst rhs) = keyword "type"
- <+> ppAppNameTypes n ks ts unicode <+> equals <+> ppType unicode rhs
+ <+> ppAppNameTypes n ks ts unicode
+ <+> maybe empty (\t -> equals <+> ppType unicode t) rhs
ppInstHead _unicode (_n, _ks, _ts, DataInst _dd) =
error "data instances not supported by --latex yet"