aboutsummaryrefslogtreecommitdiff
path: root/html-test
diff options
context:
space:
mode:
authorKazu Yamamoto <kazu@iij.ad.jp>2013-02-01 11:59:24 +0900
committerKazu Yamamoto <kazu@iij.ad.jp>2013-02-01 11:59:24 +0900
commit8d4c94ca5a969a5ebbb791939fb0195dc672429e (patch)
tree560a944a7105cd715f9acba46790bd7e1a77f82f /html-test
parent266a20afd2d27f28bbb62839ebc3f70bd83bfcce (diff)
parent3d25ea2929a9a9bd0768339b8ac5fd1b7c4670ad (diff)
Merge branch 'ghc-7.6' into ghc-7.6-merge-2
Conflicts: haddock.cabal src/Haddock/Interface/AttachInstances.hs src/Haddock/Interface/Create.hs src/Haddock/Interface/LexParseRn.hs src/Haddock/InterfaceFile.hs src/Haddock/Types.hs Only GHC HEAD can compile this. GHC 7.6.x cannot compile this. Some test fail.
Diffstat (limited to 'html-test')
-rw-r--r--html-test/README.markdown27
-rwxr-xr-xhtml-test/accept.lhs49
-rw-r--r--html-test/ref/A.html183
-rw-r--r--html-test/ref/AdvanceTypes.html97
-rw-r--r--html-test/ref/B.html175
-rw-r--r--html-test/ref/Bug1.html103
-rw-r--r--html-test/ref/Bug2.html65
-rw-r--r--html-test/ref/Bug3.html83
-rw-r--r--html-test/ref/Bug4.html82
-rw-r--r--html-test/ref/Bug6.html335
-rw-r--r--html-test/ref/Bug7.html173
-rw-r--r--html-test/ref/Bug8.html131
-rw-r--r--html-test/ref/BugDeprecated.html198
-rw-r--r--html-test/ref/BugExportHeadings.html220
-rw-r--r--html-test/ref/Bugs.html81
-rw-r--r--html-test/ref/CrossPackageDocs.html298
-rw-r--r--html-test/ref/DeprecatedClass.html161
-rw-r--r--html-test/ref/DeprecatedData.html198
-rw-r--r--html-test/ref/DeprecatedFunction.html110
-rw-r--r--html-test/ref/DeprecatedFunction2.html84
-rw-r--r--html-test/ref/DeprecatedFunction3.html84
-rw-r--r--html-test/ref/DeprecatedModule.html83
-rw-r--r--html-test/ref/DeprecatedModule2.html76
-rw-r--r--html-test/ref/DeprecatedNewtype.html161
-rw-r--r--html-test/ref/DeprecatedReExport.html133
-rw-r--r--html-test/ref/DeprecatedRecord.html151
-rw-r--r--html-test/ref/DeprecatedTypeFamily.html108
-rw-r--r--html-test/ref/DeprecatedTypeSynonym.html116
-rw-r--r--html-test/ref/DeprecationMessageParseError.html101
-rw-r--r--html-test/ref/Examples.html179
-rw-r--r--html-test/ref/FunArgs.html176
-rw-r--r--html-test/ref/GADTRecords.html234
-rw-r--r--html-test/ref/Hash.html337
-rw-r--r--html-test/ref/HiddenInstances.html169
-rw-r--r--html-test/ref/HiddenInstancesB.html143
-rw-r--r--html-test/ref/Hyperlinks.html89
-rw-r--r--html-test/ref/IgnoreExports.html101
-rw-r--r--html-test/ref/ModuleWithWarning.html83
-rw-r--r--html-test/ref/NamedDoc.html68
-rw-r--r--html-test/ref/NoLayout.html86
-rw-r--r--html-test/ref/NonGreedy.html82
-rw-r--r--html-test/ref/Properties.html92
-rw-r--r--html-test/ref/PruneWithWarning.html72
-rw-r--r--html-test/ref/QuasiExpr.html221
-rw-r--r--html-test/ref/QuasiQuote.html65
-rw-r--r--html-test/ref/SpuriousSuperclassConstraints.html128
-rw-r--r--html-test/ref/TH.html63
-rw-r--r--html-test/ref/TH2.html63
-rw-r--r--html-test/ref/Test.html2245
-rw-r--r--html-test/ref/Ticket112.html82
-rw-r--r--html-test/ref/Ticket61.html80
-rw-r--r--html-test/ref/Ticket75.html116
-rw-r--r--html-test/ref/TypeFamilies.html212
-rw-r--r--html-test/ref/TypeOperators.html185
-rw-r--r--html-test/ref/Unicode.html82
-rw-r--r--html-test/ref/Visible.html67
-rw-r--r--html-test/ref/frames.html30
-rw-r--r--html-test/ref/haddock-util.js344
-rw-r--r--html-test/ref/hslogo-16.pngbin0 -> 1684 bytes
-rw-r--r--html-test/ref/mini_A.html59
-rw-r--r--html-test/ref/mini_AdvanceTypes.html33
-rw-r--r--html-test/ref/mini_B.html45
-rw-r--r--html-test/ref/mini_Bug1.html33
-rw-r--r--html-test/ref/mini_Bug2.html31
-rw-r--r--html-test/ref/mini_Bug3.html31
-rw-r--r--html-test/ref/mini_Bug4.html31
-rw-r--r--html-test/ref/mini_Bug6.html65
-rw-r--r--html-test/ref/mini_Bug7.html41
-rw-r--r--html-test/ref/mini_Bug8.html63
-rw-r--r--html-test/ref/mini_BugDeprecated.html61
-rw-r--r--html-test/ref/mini_BugExportHeadings.html79
-rw-r--r--html-test/ref/mini_Bugs.html33
-rw-r--r--html-test/ref/mini_CrossPackageDocs.html45
-rw-r--r--html-test/ref/mini_DeprecatedClass.html41
-rw-r--r--html-test/ref/mini_DeprecatedData.html41
-rw-r--r--html-test/ref/mini_DeprecatedFunction.html37
-rw-r--r--html-test/ref/mini_DeprecatedFunction2.html31
-rw-r--r--html-test/ref/mini_DeprecatedFunction3.html31
-rw-r--r--html-test/ref/mini_DeprecatedModule.html31
-rw-r--r--html-test/ref/mini_DeprecatedModule2.html31
-rw-r--r--html-test/ref/mini_DeprecatedNewtype.html41
-rw-r--r--html-test/ref/mini_DeprecatedReExport.html37
-rw-r--r--html-test/ref/mini_DeprecatedRecord.html33
-rw-r--r--html-test/ref/mini_DeprecatedTypeFamily.html41
-rw-r--r--html-test/ref/mini_DeprecatedTypeSynonym.html41
-rw-r--r--html-test/ref/mini_DeprecationMessageParseError.html31
-rw-r--r--html-test/ref/mini_Examples.html31
-rw-r--r--html-test/ref/mini_FunArgs.html37
-rw-r--r--html-test/ref/mini_GADTRecords.html33
-rw-r--r--html-test/ref/mini_Hash.html74
-rw-r--r--html-test/ref/mini_HiddenInstances.html41
-rw-r--r--html-test/ref/mini_HiddenInstancesB.html41
-rw-r--r--html-test/ref/mini_Hyperlinks.html31
-rw-r--r--html-test/ref/mini_IgnoreExports.html37
-rw-r--r--html-test/ref/mini_ModuleWithWarning.html31
-rw-r--r--html-test/ref/mini_NamedDoc.html25
-rw-r--r--html-test/ref/mini_NoLayout.html31
-rw-r--r--html-test/ref/mini_NonGreedy.html31
-rw-r--r--html-test/ref/mini_Properties.html31
-rw-r--r--html-test/ref/mini_PruneWithWarning.html25
-rw-r--r--html-test/ref/mini_QuasiExpr.html59
-rw-r--r--html-test/ref/mini_QuasiQuote.html31
-rw-r--r--html-test/ref/mini_SpuriousSuperclassConstraints.html33
-rw-r--r--html-test/ref/mini_TH.html31
-rw-r--r--html-test/ref/mini_TH2.html31
-rw-r--r--html-test/ref/mini_Test.html269
-rw-r--r--html-test/ref/mini_Ticket112.html31
-rw-r--r--html-test/ref/mini_Ticket61.html33
-rw-r--r--html-test/ref/mini_Ticket75.html39
-rw-r--r--html-test/ref/mini_TypeFamilies.html55
-rw-r--r--html-test/ref/mini_TypeOperators.html66
-rw-r--r--html-test/ref/mini_Unicode.html31
-rw-r--r--html-test/ref/mini_Visible.html31
-rw-r--r--html-test/ref/minus.gifbin0 -> 56 bytes
-rw-r--r--html-test/ref/ocean.css546
-rw-r--r--html-test/ref/plus.gifbin0 -> 59 bytes
-rw-r--r--html-test/ref/synopsis.pngbin0 -> 11327 bytes
-rwxr-xr-xhtml-test/run.lhs156
-rw-r--r--html-test/src/A.hs17
-rw-r--r--html-test/src/AdvanceTypes.hs9
-rw-r--r--html-test/src/B.hs8
-rw-r--r--html-test/src/Bug1.hs6
-rw-r--r--html-test/src/Bug2.hs4
-rw-r--r--html-test/src/Bug3.hs6
-rw-r--r--html-test/src/Bug4.hs5
-rw-r--r--html-test/src/Bug6.hs23
-rw-r--r--html-test/src/Bug7.hs12
-rw-r--r--html-test/src/Bug8.hs14
-rw-r--r--html-test/src/BugDeprecated.hs18
-rw-r--r--html-test/src/BugExportHeadings.hs29
-rw-r--r--html-test/src/Bugs.hs3
-rw-r--r--html-test/src/CrossPackageDocs.hs4
-rw-r--r--html-test/src/DeprecatedClass.hs15
-rw-r--r--html-test/src/DeprecatedData.hs15
-rw-r--r--html-test/src/DeprecatedFunction.hs10
-rw-r--r--html-test/src/DeprecatedFunction2.hs6
-rw-r--r--html-test/src/DeprecatedFunction3.hs6
-rw-r--r--html-test/src/DeprecatedModule.hs5
-rw-r--r--html-test/src/DeprecatedModule2.hs4
-rw-r--r--html-test/src/DeprecatedNewtype.hs10
-rw-r--r--html-test/src/DeprecatedReExport.hs16
-rw-r--r--html-test/src/DeprecatedRecord.hs9
-rw-r--r--html-test/src/DeprecatedTypeFamily.hs9
-rw-r--r--html-test/src/DeprecatedTypeSynonym.hs9
-rw-r--r--html-test/src/DeprecationMessageParseError.hs12
-rw-r--r--html-test/src/Examples.hs39
-rw-r--r--html-test/src/FunArgs.hs16
-rw-r--r--html-test/src/GADTRecords.hs12
-rw-r--r--html-test/src/Hash.hs51
-rw-r--r--html-test/src/Hidden.hs6
-rw-r--r--html-test/src/HiddenInstances.hs35
-rw-r--r--html-test/src/HiddenInstancesA.hs17
-rw-r--r--html-test/src/HiddenInstancesB.hs2
-rw-r--r--html-test/src/Hyperlinks.hs8
-rw-r--r--html-test/src/IgnoreExports.hs10
-rw-r--r--html-test/src/ModuleWithWarning.hs5
-rw-r--r--html-test/src/NamedDoc.hs4
-rw-r--r--html-test/src/NoLayout.hs12
-rw-r--r--html-test/src/NonGreedy.hs5
-rw-r--r--html-test/src/Properties.hs9
-rw-r--r--html-test/src/PruneWithWarning.hs15
-rw-r--r--html-test/src/QuasiExpr.hs34
-rw-r--r--html-test/src/QuasiQuote.hs9
-rw-r--r--html-test/src/SpuriousSuperclassConstraints.hs30
-rw-r--r--html-test/src/TH.hs8
-rw-r--r--html-test/src/TH2.hs7
-rw-r--r--html-test/src/Test.hs422
-rw-r--r--html-test/src/Ticket112.hs9
-rw-r--r--html-test/src/Ticket61.hs3
-rw-r--r--html-test/src/Ticket61_Hidden.hs7
-rw-r--r--html-test/src/Ticket75.hs7
-rw-r--r--html-test/src/TypeFamilies.hs28
-rw-r--r--html-test/src/TypeOperators.hs20
-rw-r--r--html-test/src/Unicode.hs.disabled6
-rw-r--r--html-test/src/Visible.hs3
175 files changed, 13941 insertions, 0 deletions
diff --git a/html-test/README.markdown b/html-test/README.markdown
new file mode 100644
index 00000000..8d57acab
--- /dev/null
+++ b/html-test/README.markdown
@@ -0,0 +1,27 @@
+This is a testsuite for Haddock that uses the concept of "golden files". That
+is, it compares output files against a set of reference files.
+
+To add a new test:
+
+ 1. Create a module in the `html-test/src` directory.
+
+ 2. Run `cabal test`. You should now have `html-test/out/<modulename>.html`.
+ The test passes since there is no reference file to compare with.
+
+ 3. To make a reference file from the output file, run
+
+ html-test/accept.lhs <modulename>
+
+Tips and tricks:
+
+To "accept" all output files (copy them to reference files), run
+
+ runhaskell accept.lhs
+
+You can run all tests despite failing tests, like so
+
+ cabal test --test-option=all
+
+You can pass extra options to haddock like so
+
+ cabal test --test-options='all --title="All Tests"'
diff --git a/html-test/accept.lhs b/html-test/accept.lhs
new file mode 100755
index 00000000..f6dfc4cd
--- /dev/null
+++ b/html-test/accept.lhs
@@ -0,0 +1,49 @@
+#!/usr/bin/env runhaskell
+\begin{code}
+{-# LANGUAGE CPP #-}
+import System.Cmd
+import System.Environment
+import System.FilePath
+import System.Directory
+import Data.List
+import Control.Applicative
+
+baseDir = takeDirectory __FILE__
+
+main :: IO ()
+main = do
+ contents <- filter (not . ignore) <$> getDirectoryContents (baseDir </> "out")
+ args <- getArgs
+ if not $ null args then
+ mapM_ copy [ baseDir </> "out" </> file | file <- contents, ".html" `isSuffixOf` file, takeBaseName file `elem` args ]
+ else
+ mapM_ copy [ baseDir </> "out" </> file | file <- contents]
+ where
+ ignore =
+ foldr (liftA2 (||)) (const False) [
+ (== ".")
+ , (== "..")
+ , (isPrefixOf "index")
+ , (isPrefixOf "doc-index")
+ ]
+
+copy :: FilePath -> IO ()
+copy file = do
+ let new = baseDir </> "ref" </> takeFileName file
+ if ".html" `isSuffixOf` file then do
+ putStrLn (file ++ " -> " ++ new)
+ stripLinks <$> readFile file >>= writeFile new
+ else do
+ -- copy css, images, etc.
+ copyFile file new
+
+stripLinks :: String -> String
+stripLinks str =
+ let prefix = "<a href=\"" in
+ case stripPrefix prefix str of
+ Just str' -> prefix ++ stripLinks (dropWhile (/= '"') str')
+ Nothing ->
+ case str of
+ [] -> []
+ x : xs -> x : stripLinks xs
+\end{code}
diff --git a/html-test/ref/A.html b/html-test/ref/A.html
new file mode 100644
index 00000000..9a60933e
--- /dev/null
+++ b/html-test/ref/A.html
@@ -0,0 +1,183 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >A</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_A.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >A</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >A</a
+ > = <a href=""
+ >A</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >other</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >test2</a
+ > :: <a href=""
+ >Bool</a
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >X</a
+ > = <a href=""
+ >X</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >reExport</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:A" class="def"
+ >A</a
+ > </p
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:A" class="def"
+ >A</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:other" class="def"
+ >other</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:test2" class="def"
+ >test2</a
+ > :: <a href=""
+ >Bool</a
+ ></p
+ ><div class="doc"
+ ><p
+ >Doc for test2
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:X" class="def"
+ >X</a
+ > </p
+ ><div class="doc"
+ ><p
+ >Should show up on the page for both modules A and B
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:X" class="def"
+ >X</a
+ ></td
+ ><td class="doc"
+ ><p
+ >Doc for consructor
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:reExport" class="def"
+ >reExport</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >Should show up on the page for both modules A and B
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/AdvanceTypes.html b/html-test/ref/AdvanceTypes.html
new file mode 100644
index 00000000..c18e13fc
--- /dev/null
+++ b/html-test/ref/AdvanceTypes.html
@@ -0,0 +1,97 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >AdvanceTypes</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_AdvanceTypes.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >AdvanceTypes</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:Pattern" class="def"
+ >Pattern</a
+ > <span class="keyword"
+ >where</span
+ ></p
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:Nil" class="def"
+ >Nil</a
+ > :: <a href=""
+ >Pattern</a
+ > `[]`</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:Cons" class="def"
+ >Cons</a
+ > :: <a href=""
+ >Maybe</a
+ > h -&gt; <a href=""
+ >Pattern</a
+ > t -&gt; <a href=""
+ >Pattern</a
+ > (h : t)</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/B.html b/html-test/ref/B.html
new file mode 100644
index 00000000..050e89a8
--- /dev/null
+++ b/html-test/ref/B.html
@@ -0,0 +1,175 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >B</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_B.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >B</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ >module <a href=""
+ >A</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >test</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >reExport</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >X</a
+ > = <a href=""
+ >X</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ >module <a href=""
+ >A</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:test" class="def"
+ >test</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >This link shouldn't work: <code
+ >other</code
+ >.
+ These links should work: <code
+ ><a href=""
+ >other</a
+ ></code
+ >, <code
+ ><a href=""
+ >sortBy</a
+ ></code
+ >, <code
+ ><a href=""
+ >test2</a
+ ></code
+ >, <code
+ ><a href=""
+ >test2</a
+ ></code
+ >, <code
+ ><a href=""
+ >fromMaybe</a
+ ></code
+ >.
+ Module link: <a href=""
+ >Prelude</a
+ >.
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:reExport" class="def"
+ >reExport</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >Should show up on the page for both modules A and B
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:X" class="def"
+ >X</a
+ > </p
+ ><div class="doc"
+ ><p
+ >Should show up on the page for both modules A and B
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:X" class="def"
+ >X</a
+ ></td
+ ><td class="doc"
+ ><p
+ >Doc for consructor
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Bug1.html b/html-test/ref/Bug1.html
new file mode 100644
index 00000000..72733816
--- /dev/null
+++ b/html-test/ref/Bug1.html
@@ -0,0 +1,103 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bug1</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Bug1.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Bug1</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >T</a
+ > = <a href=""
+ >T</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:T" class="def"
+ >T</a
+ > </p
+ ><div class="doc"
+ ><p
+ >We should have different anchors for constructors and types/classes. This
+ hyperlink should point to the type constructor by default: <code
+ ><a href=""
+ >T</a
+ ></code
+ >.
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:T" class="def"
+ >T</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Bug2.html b/html-test/ref/Bug2.html
new file mode 100644
index 00000000..a6a65b1e
--- /dev/null
+++ b/html-test/ref/Bug2.html
@@ -0,0 +1,65 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bug2</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Bug2.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Bug2</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:x" class="def"
+ >x</a
+ > :: <a href=""
+ >A</a
+ ></p
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Bug3.html b/html-test/ref/Bug3.html
new file mode 100644
index 00000000..2c32e070
--- /dev/null
+++ b/html-test/ref/Bug3.html
@@ -0,0 +1,83 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bug3</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Bug3.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Bug3</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >/multi-line
+ emphasis/
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Bug4.html b/html-test/ref/Bug4.html
new file mode 100644
index 00000000..ba726c27
--- /dev/null
+++ b/html-test/ref/Bug4.html
@@ -0,0 +1,82 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bug4</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Bug4.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Bug4</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >don't use apostrophe's in the wrong place's
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Bug6.html b/html-test/ref/Bug6.html
new file mode 100644
index 00000000..17fab740
--- /dev/null
+++ b/html-test/ref/Bug6.html
@@ -0,0 +1,335 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bug6</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Bug6.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Bug6</p
+ ></div
+ ><div id="description"
+ ><p class="caption"
+ >Description</p
+ ><div class="doc"
+ ><p
+ >Exporting records.
+</p
+ ></div
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >A</a
+ > = <a href=""
+ >A</a
+ > <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >B</a
+ > = <a href=""
+ >B</a
+ > {<ul class="subs"
+ ><li
+ ><a href=""
+ >b</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ >}</li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >C</a
+ > = <a href=""
+ >C</a
+ > {<ul class="subs"
+ ><li
+ ><a href=""
+ >c1</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li
+ ><a href=""
+ >c2</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ >}</li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >D</a
+ > = <a href=""
+ >D</a
+ > <a href=""
+ >Int</a
+ > <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >newtype</span
+ > <a href=""
+ >E</a
+ > = <a href=""
+ >E</a
+ > <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:A" class="def"
+ >A</a
+ > </p
+ ><div class="doc"
+ ><p
+ >This record is exported without its field
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:A" class="def"
+ >A</a
+ > <a href=""
+ >Int</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:B" class="def"
+ >B</a
+ > </p
+ ><div class="doc"
+ ><p
+ >.. with its field, but the field is named separately in the export list
+ (the field isn't documented separately since it is already documented here)
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:B" class="def"
+ >B</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td colspan="2"
+ ><div class="subs fields"
+ ><p class="caption"
+ >Fields</p
+ ><dl
+ ><dt class="src"
+ ><a name="v:b" class="def"
+ >b</a
+ > :: <a href=""
+ >Int</a
+ ></dt
+ ><dd class="doc empty"
+ >&nbsp;</dd
+ ></dl
+ ><div class="clear"
+ ></div
+ ></div
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:C" class="def"
+ >C</a
+ > </p
+ ><div class="doc"
+ ><p
+ >.. with fields names as subordinate names in the export
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:C" class="def"
+ >C</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td colspan="2"
+ ><div class="subs fields"
+ ><p class="caption"
+ >Fields</p
+ ><dl
+ ><dt class="src"
+ ><a name="v:c1" class="def"
+ >c1</a
+ > :: <a href=""
+ >Int</a
+ ></dt
+ ><dd class="doc empty"
+ >&nbsp;</dd
+ ><dt class="src"
+ ><a name="v:c2" class="def"
+ >c2</a
+ > :: <a href=""
+ >Int</a
+ ></dt
+ ><dd class="doc empty"
+ >&nbsp;</dd
+ ></dl
+ ><div class="clear"
+ ></div
+ ></div
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:D" class="def"
+ >D</a
+ > </p
+ ><div class="doc"
+ ><p
+ >.. with only some of the fields exported (we can't handle this one -
+ how do we render the declaration?)
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:D" class="def"
+ >D</a
+ > <a href=""
+ >Int</a
+ > <a href=""
+ >Int</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >newtype</span
+ > <a name="t:E" class="def"
+ >E</a
+ > </p
+ ><div class="doc"
+ ><p
+ >a newtype with a field
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:E" class="def"
+ >E</a
+ > <a href=""
+ >Int</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Bug7.html b/html-test/ref/Bug7.html
new file mode 100644
index 00000000..a86a75c2
--- /dev/null
+++ b/html-test/ref/Bug7.html
@@ -0,0 +1,173 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bug7</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Bug7.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Bug7</p
+ ></div
+ ><div id="description"
+ ><p class="caption"
+ >Description</p
+ ><div class="doc"
+ ><p
+ >This module caused a duplicate instance in the documentation for the Foo
+ type.
+</p
+ ></div
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >Foo</a
+ > = <a href=""
+ >Foo</a
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >class</span
+ > <a href=""
+ >Bar</a
+ > x y </li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:Foo" class="def"
+ >Foo</a
+ > </p
+ ><div class="doc"
+ ><p
+ >The Foo datatype
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:Foo" class="def"
+ >Foo</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ><div class="subs instances"
+ ><p id="control.i:Foo" class="caption collapser" onclick="toggleSection('i:Foo')"
+ >Instances</p
+ ><div id="section.i:Foo" class="show"
+ ><table
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >Bar</a
+ > <a href=""
+ >Foo</a
+ > <a href=""
+ >Foo</a
+ ></td
+ ><td class="doc"
+ ><p
+ >Just one instance
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a name="t:Bar" class="def"
+ >Bar</a
+ > x y </p
+ ><div class="doc"
+ ><p
+ >The Bar class
+</p
+ ></div
+ ><div class="subs instances"
+ ><p id="control.i:Bar" class="caption collapser" onclick="toggleSection('i:Bar')"
+ >Instances</p
+ ><div id="section.i:Bar" class="show"
+ ><table
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >Bar</a
+ > <a href=""
+ >Foo</a
+ > <a href=""
+ >Foo</a
+ ></td
+ ><td class="doc"
+ ><p
+ >Just one instance
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Bug8.html b/html-test/ref/Bug8.html
new file mode 100644
index 00000000..4655db6f
--- /dev/null
+++ b/html-test/ref/Bug8.html
@@ -0,0 +1,131 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bug8</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Bug8.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Bug8</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:Typ" class="def"
+ >Typ</a
+ > </p
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:Type" class="def"
+ >Type</a
+ > (<a href=""
+ >String</a
+ >, [<a href=""
+ >Typ</a
+ >])</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:TFree" class="def"
+ >TFree</a
+ > (<a href=""
+ >String</a
+ >, [<a href=""
+ >String</a
+ >])</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:-45--45--62-" class="def"
+ >(--&gt;)</a
+ > :: t -&gt; t1 -&gt; <a href=""
+ >Typ</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:-45--45--45--62-" class="def"
+ >(---&gt;)</a
+ > :: [a] -&gt; <a href=""
+ >Typ</a
+ > -&gt; <a href=""
+ >Typ</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:s" class="def"
+ >s</a
+ > :: a</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:t" class="def"
+ >t</a
+ > :: a</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:main" class="def"
+ >main</a
+ > :: a</p
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/BugDeprecated.html b/html-test/ref/BugDeprecated.html
new file mode 100644
index 00000000..879b04fc
--- /dev/null
+++ b/html-test/ref/BugDeprecated.html
@@ -0,0 +1,198 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >BugDeprecated</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_BugDeprecated.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >BugDeprecated</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >baz</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >bar</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >one</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >three</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >two</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: for foo
+</p
+ ></div
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:baz" class="def"
+ >baz</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: for baz
+</p
+ ></div
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:bar" class="def"
+ >bar</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: for bar
+</p
+ ></div
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:one" class="def"
+ >one</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: for one
+</p
+ ></div
+ ><p
+ >some documentation for one, two and three
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:three" class="def"
+ >three</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: for three
+</p
+ ></div
+ ><p
+ >some documentation for one, two and three
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:two" class="def"
+ >two</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: for two
+</p
+ ></div
+ ><p
+ >some documentation for one, two and three
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/BugExportHeadings.html b/html-test/ref/BugExportHeadings.html
new file mode 100644
index 00000000..4832d7fb
--- /dev/null
+++ b/html-test/ref/BugExportHeadings.html
@@ -0,0 +1,220 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >BugExportHeadings</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_BugExportHeadings.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >BugExportHeadings</p
+ ></div
+ ><div id="table-of-contents"
+ ><p class="caption"
+ >Contents</p
+ ><ul
+ ><li
+ ><a href=""
+ >Foo
+</a
+ ></li
+ ><li
+ ><a href=""
+ >Bar
+</a
+ ></li
+ ><li
+ ><a href=""
+ >Baz
+</a
+ ></li
+ ><li
+ ><a href=""
+ >One
+</a
+ ></li
+ ><li
+ ><a href=""
+ >Two
+</a
+ ></li
+ ><li
+ ><a href=""
+ >Three
+</a
+ ></li
+ ></ul
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >bar</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >baz</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >one</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >two</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >three</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1 id="g:1"
+ >Foo
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ></div
+ ><h1 id="g:2"
+ >Bar
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:bar" class="def"
+ >bar</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ></div
+ ><h1 id="g:3"
+ >Baz
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:baz" class="def"
+ >baz</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ></div
+ ><h1 id="g:4"
+ >One
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:one" class="def"
+ >one</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: for one
+</p
+ ></div
+ ></div
+ ></div
+ ><h1 id="g:5"
+ >Two
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:two" class="def"
+ >two</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: for two
+</p
+ ></div
+ ></div
+ ></div
+ ><h1 id="g:6"
+ >Three
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:three" class="def"
+ >three</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: for three
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Bugs.html b/html-test/ref/Bugs.html
new file mode 100644
index 00000000..96fbe9e8
--- /dev/null
+++ b/html-test/ref/Bugs.html
@@ -0,0 +1,81 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bugs</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Bugs.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Bugs</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:A" class="def"
+ >A</a
+ > a </p
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:A" class="def"
+ >A</a
+ > a (a -&gt; <a href=""
+ >Int</a
+ >)</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/CrossPackageDocs.html b/html-test/ref/CrossPackageDocs.html
new file mode 100644
index 00000000..e2925558
--- /dev/null
+++ b/html-test/ref/CrossPackageDocs.html
@@ -0,0 +1,298 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >CrossPackageDocs</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_CrossPackageDocs.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >CrossPackageDocs</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >map</a
+ > :: (a -&gt; b) -&gt; [a] -&gt; [b]</li
+ ><li class="src short"
+ ><span class="keyword"
+ >class</span
+ > <a href=""
+ >IsString</a
+ > a <span class="keyword"
+ >where</span
+ ><ul class="subs"
+ ><li
+ ><a href=""
+ >fromString</a
+ > :: <a href=""
+ >String</a
+ > -&gt; a</li
+ ></ul
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >runInteractiveProcess</a
+ > :: <a href=""
+ >FilePath</a
+ > -&gt; [<a href=""
+ >String</a
+ >] -&gt; <a href=""
+ >Maybe</a
+ > <a href=""
+ >FilePath</a
+ > -&gt; <a href=""
+ >Maybe</a
+ > [(<a href=""
+ >String</a
+ >, <a href=""
+ >String</a
+ >)] -&gt; <a href=""
+ >IO</a
+ > (<a href=""
+ >Handle</a
+ >, <a href=""
+ >Handle</a
+ >, <a href=""
+ >Handle</a
+ >, <a href=""
+ >ProcessHandle</a
+ >)</li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:map" class="def"
+ >map</a
+ > :: (a -&gt; b) -&gt; [a] -&gt; [b]</p
+ ><div class="doc"
+ ><p
+ ><code
+ ><a href=""
+ >map</a
+ ></code
+ > <code
+ >f xs</code
+ > is the list obtained by applying <code
+ >f</code
+ > to each element
+ of <code
+ >xs</code
+ >, i.e.,
+</p
+ ><pre
+ > map f [x1, x2, ..., xn] == [f x1, f x2, ..., f xn]
+ map f [x1, x2, ...] == [f x1, f x2, ...]
+</pre
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a name="t:IsString" class="def"
+ >IsString</a
+ > a <span class="keyword"
+ >where</span
+ ></p
+ ><div class="doc"
+ ><p
+ >Class for string-like datastructures; used by the overloaded string
+ extension (-foverloaded-strings in GHC).
+</p
+ ></div
+ ><div class="subs methods"
+ ><p class="caption"
+ >Methods</p
+ ><p class="src"
+ ><a name="v:fromString" class="def"
+ >fromString</a
+ > :: <a href=""
+ >String</a
+ > -&gt; a</p
+ ></div
+ ><div class="subs instances"
+ ><p id="control.i:IsString" class="caption collapser" onclick="toggleSection('i:IsString')"
+ >Instances</p
+ ><div id="section.i:IsString" class="show"
+ ><table
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >IsString</a
+ > [<a href=""
+ >Char</a
+ >]</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:runInteractiveProcess" class="def"
+ >runInteractiveProcess</a
+ ></p
+ ><div class="subs arguments"
+ ><p class="caption"
+ >Arguments</p
+ ><table
+ ><tr
+ ><td class="src"
+ >:: <a href=""
+ >FilePath</a
+ ></td
+ ><td class="doc"
+ ><p
+ >Filename of the executable (see <code
+ ><a href=""
+ >proc</a
+ ></code
+ > for details)
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; [<a href=""
+ >String</a
+ >]</td
+ ><td class="doc"
+ ><p
+ >Arguments to pass to the executable
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; <a href=""
+ >Maybe</a
+ > <a href=""
+ >FilePath</a
+ ></td
+ ><td class="doc"
+ ><p
+ >Optional path to the working directory
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; <a href=""
+ >Maybe</a
+ > [(<a href=""
+ >String</a
+ >, <a href=""
+ >String</a
+ >)]</td
+ ><td class="doc"
+ ><p
+ >Optional environment (otherwise inherit)
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; <a href=""
+ >IO</a
+ > (<a href=""
+ >Handle</a
+ >, <a href=""
+ >Handle</a
+ >, <a href=""
+ >Handle</a
+ >, <a href=""
+ >ProcessHandle</a
+ >)</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ><div class="doc"
+ ><p
+ >Runs a raw command, and returns <code
+ ><a href=""
+ >Handle</a
+ ></code
+ >s that may be used to communicate
+ with the process via its <code
+ >stdin</code
+ >, <code
+ >stdout</code
+ > and <code
+ >stderr</code
+ > respectively.
+</p
+ ><p
+ >For example, to start a process and feed a string to its stdin:
+</p
+ ><pre
+ > (inp,out,err,pid) &lt;- runInteractiveProcess &quot;...&quot;
+ forkIO (hPutStr inp str)
+</pre
+ ><p
+ >The <code
+ ><a href=""
+ >Handle</a
+ ></code
+ >s are initially in binary mode; if you need them to be
+ in text mode then use <code
+ ><a href=""
+ >hSetBinaryMode</a
+ ></code
+ >.
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/DeprecatedClass.html b/html-test/ref/DeprecatedClass.html
new file mode 100644
index 00000000..f73216ba
--- /dev/null
+++ b/html-test/ref/DeprecatedClass.html
@@ -0,0 +1,161 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedClass</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_DeprecatedClass.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >DeprecatedClass</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >class</span
+ > <a href=""
+ >SomeClass</a
+ > a <span class="keyword"
+ >where</span
+ ><ul class="subs"
+ ><li
+ ><a href=""
+ >foo</a
+ > :: a -&gt; a</li
+ ></ul
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >class</span
+ > <a href=""
+ >SomeOtherClass</a
+ > a <span class="keyword"
+ >where</span
+ ><ul class="subs"
+ ><li
+ ><a href=""
+ >bar</a
+ > :: a -&gt; a</li
+ ></ul
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a name="t:SomeClass" class="def"
+ >SomeClass</a
+ > a <span class="keyword"
+ >where</span
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: SomeClass
+</p
+ ></div
+ ><p
+ >some class
+</p
+ ></div
+ ><div class="subs methods"
+ ><p class="caption"
+ >Methods</p
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: a -&gt; a</p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: foo
+</p
+ ></div
+ ><p
+ >documentation for foo
+</p
+ ></div
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a name="t:SomeOtherClass" class="def"
+ >SomeOtherClass</a
+ > a <span class="keyword"
+ >where</span
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: SomeOtherClass
+</p
+ ></div
+ ></div
+ ><div class="subs methods"
+ ><p class="caption"
+ >Methods</p
+ ><p class="src"
+ ><a name="v:bar" class="def"
+ >bar</a
+ > :: a -&gt; a</p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: bar
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/DeprecatedData.html b/html-test/ref/DeprecatedData.html
new file mode 100644
index 00000000..d1a29021
--- /dev/null
+++ b/html-test/ref/DeprecatedData.html
@@ -0,0 +1,198 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedData</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_DeprecatedData.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >DeprecatedData</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >Foo</a
+ > <ul class="subs"
+ ><li
+ >= <a href=""
+ >Foo</a
+ > </li
+ ><li
+ >| <a href=""
+ >Bar</a
+ > </li
+ ></ul
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >One</a
+ > <ul class="subs"
+ ><li
+ >= <a href=""
+ >One</a
+ > </li
+ ><li
+ >| <a href=""
+ >Two</a
+ > </li
+ ></ul
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:Foo" class="def"
+ >Foo</a
+ > </p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: Foo
+</p
+ ></div
+ ><p
+ >type Foo
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:Foo" class="def"
+ >Foo</a
+ ></td
+ ><td class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: Foo
+</p
+ ></div
+ ><p
+ >constructor Foo
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:Bar" class="def"
+ >Bar</a
+ ></td
+ ><td class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: Bar
+</p
+ ></div
+ ><p
+ >constructor Bar
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:One" class="def"
+ >One</a
+ > </p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: One
+</p
+ ></div
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:One" class="def"
+ >One</a
+ ></td
+ ><td class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: One
+</p
+ ></div
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:Two" class="def"
+ >Two</a
+ ></td
+ ><td class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: Two
+</p
+ ></div
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/DeprecatedFunction.html b/html-test/ref/DeprecatedFunction.html
new file mode 100644
index 00000000..8d0e7d6b
--- /dev/null
+++ b/html-test/ref/DeprecatedFunction.html
@@ -0,0 +1,110 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedFunction</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_DeprecatedFunction.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >DeprecatedFunction</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >bar</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: use <code
+ ><a href=""
+ >bar</a
+ ></code
+ > instead
+</p
+ ></div
+ ><p
+ >some documentation for foo
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:bar" class="def"
+ >bar</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >some documentation for bar
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/DeprecatedFunction2.html b/html-test/ref/DeprecatedFunction2.html
new file mode 100644
index 00000000..9c7fd335
--- /dev/null
+++ b/html-test/ref/DeprecatedFunction2.html
@@ -0,0 +1,84 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedFunction2</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_DeprecatedFunction2.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >DeprecatedFunction2</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: use bar instead
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/DeprecatedFunction3.html b/html-test/ref/DeprecatedFunction3.html
new file mode 100644
index 00000000..0db7b8be
--- /dev/null
+++ b/html-test/ref/DeprecatedFunction3.html
@@ -0,0 +1,84 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedFunction3</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_DeprecatedFunction3.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >DeprecatedFunction3</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >foo</a
+ > :: <a href=""
+ >Integer</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: <a href=""
+ >Integer</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: use bar instead
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/DeprecatedModule.html b/html-test/ref/DeprecatedModule.html
new file mode 100644
index 00000000..7ab5dcf8
--- /dev/null
+++ b/html-test/ref/DeprecatedModule.html
@@ -0,0 +1,83 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedModule</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_DeprecatedModule.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >DeprecatedModule</p
+ ></div
+ ><div id="description"
+ ><p class="caption"
+ >Description</p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: Use <a href=""
+ >Foo</a
+ > instead
+</p
+ ></div
+ ><p
+ >Documentation for <a href=""
+ >DeprecatedModule</a
+ >.
+</p
+ ></div
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/DeprecatedModule2.html b/html-test/ref/DeprecatedModule2.html
new file mode 100644
index 00000000..f33e5681
--- /dev/null
+++ b/html-test/ref/DeprecatedModule2.html
@@ -0,0 +1,76 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedModule2</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_DeprecatedModule2.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >DeprecatedModule2</p
+ ></div
+ ><div id="description"
+ ><p class="caption"
+ >Description</p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: Use Foo instead
+</p
+ ></div
+ ></div
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/DeprecatedNewtype.html b/html-test/ref/DeprecatedNewtype.html
new file mode 100644
index 00000000..1cd59ab0
--- /dev/null
+++ b/html-test/ref/DeprecatedNewtype.html
@@ -0,0 +1,161 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedNewtype</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_DeprecatedNewtype.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >DeprecatedNewtype</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >newtype</span
+ > <a href=""
+ >SomeNewType</a
+ > = <a href=""
+ >SomeNewTypeConst</a
+ > <a href=""
+ >String</a
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >newtype</span
+ > <a href=""
+ >SomeOtherNewType</a
+ > = <a href=""
+ >SomeOtherNewTypeConst</a
+ > <a href=""
+ >String</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >newtype</span
+ > <a name="t:SomeNewType" class="def"
+ >SomeNewType</a
+ > </p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: SomeNewType
+</p
+ ></div
+ ><p
+ >some documentation
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:SomeNewTypeConst" class="def"
+ >SomeNewTypeConst</a
+ > <a href=""
+ >String</a
+ ></td
+ ><td class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: SomeNewTypeConst
+</p
+ ></div
+ ><p
+ >constructor docu
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >newtype</span
+ > <a name="t:SomeOtherNewType" class="def"
+ >SomeOtherNewType</a
+ > </p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: SomeOtherNewType
+</p
+ ></div
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:SomeOtherNewTypeConst" class="def"
+ >SomeOtherNewTypeConst</a
+ > <a href=""
+ >String</a
+ ></td
+ ><td class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: SomeOtherNewTypeConst
+</p
+ ></div
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/DeprecatedReExport.html b/html-test/ref/DeprecatedReExport.html
new file mode 100644
index 00000000..b75850c3
--- /dev/null
+++ b/html-test/ref/DeprecatedReExport.html
@@ -0,0 +1,133 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedReExport</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_DeprecatedReExport.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >DeprecatedReExport</p
+ ></div
+ ><div id="table-of-contents"
+ ><p class="caption"
+ >Contents</p
+ ><ul
+ ><li
+ ><a href=""
+ >Re-exported from an other module
+</a
+ ></li
+ ><li
+ ><a href=""
+ >Re-exported from an other package
+</a
+ ></li
+ ></ul
+ ></div
+ ><div id="description"
+ ><p class="caption"
+ >Description</p
+ ><div class="doc"
+ ><p
+ >What is tested here:
+</p
+ ><ul
+ ><li
+ > Deprecation messages are shown for re-exported items.
+</li
+ ></ul
+ ></div
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1 id="g:1"
+ >Re-exported from an other module
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: use <code
+ ><a href=""
+ >bar</a
+ ></code
+ > instead
+</p
+ ></div
+ ><p
+ >some documentation for foo
+</p
+ ></div
+ ></div
+ ><h1 id="g:2"
+ >Re-exported from an other package
+</h1
+ ><div class="doc"
+ ><p
+ >Not yet working, see <a href=""
+ >http://trac.haskell.org/haddock/ticket/223</a
+ >
+ , isEmptyChan
+</p
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/DeprecatedRecord.html b/html-test/ref/DeprecatedRecord.html
new file mode 100644
index 00000000..62d07c45
--- /dev/null
+++ b/html-test/ref/DeprecatedRecord.html
@@ -0,0 +1,151 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedRecord</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_DeprecatedRecord.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >DeprecatedRecord</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >Foo</a
+ > = <a href=""
+ >Foo</a
+ > {<ul class="subs"
+ ><li
+ ><a href=""
+ >fooName</a
+ > :: <a href=""
+ >String</a
+ ></li
+ ><li
+ ><a href=""
+ >fooValue</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ >}</li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:Foo" class="def"
+ >Foo</a
+ > </p
+ ><div class="doc"
+ ><p
+ >type Foo
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:Foo" class="def"
+ >Foo</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td colspan="2"
+ ><div class="subs fields"
+ ><p class="caption"
+ >Fields</p
+ ><dl
+ ><dt class="src"
+ ><a name="v:fooName" class="def"
+ >fooName</a
+ > :: <a href=""
+ >String</a
+ ></dt
+ ><dd class="doc"
+ ><p
+ >some name
+</p
+ ></dd
+ ><dt class="src"
+ ><a name="v:fooValue" class="def"
+ >fooValue</a
+ > :: <a href=""
+ >Int</a
+ ></dt
+ ><dd class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: do not use this
+</p
+ ></div
+ ><p
+ >some value
+</p
+ ></dd
+ ></dl
+ ><div class="clear"
+ ></div
+ ></div
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/DeprecatedTypeFamily.html b/html-test/ref/DeprecatedTypeFamily.html
new file mode 100644
index 00000000..4b73c301
--- /dev/null
+++ b/html-test/ref/DeprecatedTypeFamily.html
@@ -0,0 +1,108 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedTypeFamily</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_DeprecatedTypeFamily.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >DeprecatedTypeFamily</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >data family</span
+ > <a href=""
+ >SomeTypeFamily</a
+ > k :: * -&gt; *</li
+ ><li class="src short"
+ ><span class="keyword"
+ >data family</span
+ > <a href=""
+ >SomeOtherTypeFamily</a
+ > k :: * -&gt; *</li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data family</span
+ > <a name="t:SomeTypeFamily" class="def"
+ >SomeTypeFamily</a
+ > k :: * -&gt; *</p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: SomeTypeFamily
+</p
+ ></div
+ ><p
+ >some documentation
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data family</span
+ > <a name="t:SomeOtherTypeFamily" class="def"
+ >SomeOtherTypeFamily</a
+ > k :: * -&gt; *</p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: SomeOtherTypeFamily
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/DeprecatedTypeSynonym.html b/html-test/ref/DeprecatedTypeSynonym.html
new file mode 100644
index 00000000..c628316e
--- /dev/null
+++ b/html-test/ref/DeprecatedTypeSynonym.html
@@ -0,0 +1,116 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedTypeSynonym</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_DeprecatedTypeSynonym.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >DeprecatedTypeSynonym</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >type</span
+ > <a href=""
+ >TypeSyn</a
+ > = <a href=""
+ >String</a
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >type</span
+ > <a href=""
+ >OtherTypeSyn</a
+ > = <a href=""
+ >String</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >type</span
+ > <a name="t:TypeSyn" class="def"
+ >TypeSyn</a
+ > = <a href=""
+ >String</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: TypeSyn
+</p
+ ></div
+ ><p
+ >some documentation
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >type</span
+ > <a name="t:OtherTypeSyn" class="def"
+ >OtherTypeSyn</a
+ > = <a href=""
+ >String</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: OtherTypeSyn
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/DeprecationMessageParseError.html b/html-test/ref/DeprecationMessageParseError.html
new file mode 100644
index 00000000..3d8f3cdf
--- /dev/null
+++ b/html-test/ref/DeprecationMessageParseError.html
@@ -0,0 +1,101 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecationMessageParseError</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_DeprecationMessageParseError.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >DeprecationMessageParseError</p
+ ></div
+ ><div id="description"
+ ><p class="caption"
+ >Description</p
+ ><div class="doc"
+ ><p
+ >What is tested here:
+</p
+ ><ul
+ ><li
+ > If parsing of a deprecation message fails, the message is included
+ verbatim.
+</li
+ ></ul
+ ></div
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Deprecated: use @bar instead</p
+ ></div
+ ><p
+ >some documentation for foo
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Examples.html b/html-test/ref/Examples.html
new file mode 100644
index 00000000..f9575eb9
--- /dev/null
+++ b/html-test/ref/Examples.html
@@ -0,0 +1,179 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Examples</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Examples.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Examples</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >fib</a
+ > :: <a href=""
+ >Integer</a
+ > -&gt; <a href=""
+ >Integer</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:fib" class="def"
+ >fib</a
+ > :: <a href=""
+ >Integer</a
+ > -&gt; <a href=""
+ >Integer</a
+ ></p
+ ><div class="doc"
+ ><p
+ >Fibonacci number of given <code
+ ><a href=""
+ >Integer</a
+ ></code
+ >.
+</p
+ ><p
+ >Examples:
+</p
+ ><pre class="screen"
+ ><code class="prompt"
+ >&gt;&gt;&gt; </code
+ ><strong class="userinput"
+ ><code
+ >fib 5
+</code
+ ></strong
+ >5
+<code class="prompt"
+ >&gt;&gt;&gt; </code
+ ><strong class="userinput"
+ ><code
+ >fib 10
+</code
+ ></strong
+ >55
+</pre
+ ><pre class="screen"
+ ><code class="prompt"
+ >&gt;&gt;&gt; </code
+ ><strong class="userinput"
+ ><code
+ >fib 10
+</code
+ ></strong
+ >55
+</pre
+ ><p
+ >One more Example:
+</p
+ ><pre class="screen"
+ ><code class="prompt"
+ >&gt;&gt;&gt; </code
+ ><strong class="userinput"
+ ><code
+ >fib 5
+</code
+ ></strong
+ >5
+</pre
+ ><p
+ >One more Example:
+</p
+ ><pre class="screen"
+ ><code class="prompt"
+ >&gt;&gt;&gt; </code
+ ><strong class="userinput"
+ ><code
+ >fib 5
+</code
+ ></strong
+ >5
+</pre
+ ><p
+ >Example with an import:
+</p
+ ><pre class="screen"
+ ><code class="prompt"
+ >&gt;&gt;&gt; </code
+ ><strong class="userinput"
+ ><code
+ >import Data.Char
+</code
+ ></strong
+ ><code class="prompt"
+ >&gt;&gt;&gt; </code
+ ><strong class="userinput"
+ ><code
+ >isSpace 'a'
+</code
+ ></strong
+ >False
+</pre
+ ><pre class="screen"
+ ><code class="prompt"
+ >&gt;&gt;&gt; </code
+ ><strong class="userinput"
+ ><code
+ >putStrLn &quot;foo\n\nbar&quot;
+</code
+ ></strong
+ >foo
+
+bar
+</pre
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/FunArgs.html b/html-test/ref/FunArgs.html
new file mode 100644
index 00000000..5c7d6c34
--- /dev/null
+++ b/html-test/ref/FunArgs.html
@@ -0,0 +1,176 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >FunArgs</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_FunArgs.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >FunArgs</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:f" class="def"
+ >f</a
+ ></p
+ ><div class="subs arguments"
+ ><p class="caption"
+ >Arguments</p
+ ><table
+ ><tr
+ ><td class="src"
+ >:: <span class="keyword"
+ >forall</span
+ > a . <a href=""
+ >Ord</a
+ > a</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ >=&gt; <a href=""
+ >Int</a
+ ></td
+ ><td class="doc"
+ ><p
+ >First argument
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; a</td
+ ><td class="doc"
+ ><p
+ >Second argument
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; <a href=""
+ >Bool</a
+ ></td
+ ><td class="doc"
+ ><p
+ >Third argument
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; (a -&gt; a)</td
+ ><td class="doc"
+ ><p
+ >Fourth argument
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; ()</td
+ ><td class="doc"
+ ><p
+ >Result
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:g" class="def"
+ >g</a
+ ></p
+ ><div class="subs arguments"
+ ><p class="caption"
+ >Arguments</p
+ ><table
+ ><tr
+ ><td class="src"
+ >:: a</td
+ ><td class="doc"
+ ><p
+ >First argument
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; b</td
+ ><td class="doc"
+ ><p
+ >Second argument
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; c</td
+ ><td class="doc"
+ ><p
+ >Third argument
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; d</td
+ ><td class="doc"
+ ><p
+ >Result
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/GADTRecords.html b/html-test/ref/GADTRecords.html
new file mode 100644
index 00000000..a040c954
--- /dev/null
+++ b/html-test/ref/GADTRecords.html
@@ -0,0 +1,234 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >GADTRecords</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_GADTRecords.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >GADTRecords</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >H1</a
+ > a b <span class="keyword"
+ >where</span
+ ><ul class="subs"
+ ><li
+ ><a href=""
+ >C1</a
+ > :: <a href=""
+ >H1</a
+ > a b </li
+ ><li
+ ><a href=""
+ >C2</a
+ > :: <a href=""
+ >Ord</a
+ > a =&gt; [a] -&gt; <a href=""
+ >H1</a
+ > a a </li
+ ><li
+ ><a href=""
+ >C3</a
+ > :: { <ul class="subs"
+ ><li
+ ><a href=""
+ >field</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ > } -&gt; <a href=""
+ >H1</a
+ > <a href=""
+ >Int</a
+ > <a href=""
+ >Int</a
+ ></li
+ ><li
+ ><a href=""
+ >C4</a
+ > :: { <ul class="subs"
+ ><li
+ ><a href=""
+ >field2</a
+ > :: a</li
+ ></ul
+ > } -&gt; <a href=""
+ >H1</a
+ > <a href=""
+ >Int</a
+ > a</li
+ ></ul
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:H1" class="def"
+ >H1</a
+ > a b <span class="keyword"
+ >where</span
+ ></p
+ ><div class="doc"
+ ><p
+ >h1
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:C1" class="def"
+ >C1</a
+ > :: <a href=""
+ >H1</a
+ > a b</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:C2" class="def"
+ >C2</a
+ > :: <a href=""
+ >Ord</a
+ > a =&gt; [a] -&gt; <a href=""
+ >H1</a
+ > a a</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:C3" class="def"
+ >C3</a
+ > :: <a href=""
+ >Int</a
+ > -&gt; <a href=""
+ >H1</a
+ > <a href=""
+ >Int</a
+ > <a href=""
+ >Int</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td colspan="2"
+ ><div class="subs fields"
+ ><p class="caption"
+ >Fields</p
+ ><dl
+ ><dt class="src"
+ ><a name="v:field" class="def"
+ >field</a
+ > :: <a href=""
+ >Int</a
+ ></dt
+ ><dd class="doc"
+ ><p
+ >hello docs
+</p
+ ></dd
+ ></dl
+ ><div class="clear"
+ ></div
+ ></div
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:C4" class="def"
+ >C4</a
+ > :: a -&gt; <a href=""
+ >H1</a
+ > <a href=""
+ >Int</a
+ > a</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td colspan="2"
+ ><div class="subs fields"
+ ><p class="caption"
+ >Fields</p
+ ><dl
+ ><dt class="src"
+ ><a name="v:field2" class="def"
+ >field2</a
+ > :: a</dt
+ ><dd class="doc"
+ ><p
+ >hello2 docs
+</p
+ ></dd
+ ></dl
+ ><div class="clear"
+ ></div
+ ></div
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Hash.html b/html-test/ref/Hash.html
new file mode 100644
index 00000000..d5f87840
--- /dev/null
+++ b/html-test/ref/Hash.html
@@ -0,0 +1,337 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Hash</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Hash.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Hash</p
+ ></div
+ ><div id="table-of-contents"
+ ><p class="caption"
+ >Contents</p
+ ><ul
+ ><li
+ ><a href=""
+ >The <code
+ >HashTable</code
+ > type
+</a
+ ><ul
+ ><li
+ ><a href=""
+ >Operations on <code
+ >HashTable</code
+ >s
+</a
+ ></li
+ ></ul
+ ></li
+ ><li
+ ><a href=""
+ >The <code
+ >Hash</code
+ > class
+</a
+ ></li
+ ></ul
+ ></div
+ ><div id="description"
+ ><p class="caption"
+ >Description</p
+ ><div class="doc"
+ ><p
+ >Implementation of fixed-size hash tables, with a type
+ class for constructing hash values for structured types.
+</p
+ ></div
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >HashTable</a
+ > key val</li
+ ><li class="src short"
+ ><a href=""
+ >new</a
+ > :: (<a href=""
+ >Eq</a
+ > key, <a href=""
+ >Hash</a
+ > key) =&gt; <a href=""
+ >Int</a
+ > -&gt; <a href=""
+ >IO</a
+ > (<a href=""
+ >HashTable</a
+ > key val)</li
+ ><li class="src short"
+ ><a href=""
+ >insert</a
+ > :: (<a href=""
+ >Eq</a
+ > key, <a href=""
+ >Hash</a
+ > key) =&gt; key -&gt; val -&gt; <a href=""
+ >IO</a
+ > ()</li
+ ><li class="src short"
+ ><a href=""
+ >lookup</a
+ > :: <a href=""
+ >Hash</a
+ > key =&gt; key -&gt; <a href=""
+ >IO</a
+ > (<a href=""
+ >Maybe</a
+ > val)</li
+ ><li class="src short"
+ ><span class="keyword"
+ >class</span
+ > <a href=""
+ >Hash</a
+ > a <span class="keyword"
+ >where</span
+ ><ul class="subs"
+ ><li
+ ><a href=""
+ >hash</a
+ > :: a -&gt; <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1 id="g:1"
+ >The <code
+ >HashTable</code
+ > type
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:HashTable" class="def"
+ >HashTable</a
+ > key val </p
+ ><div class="doc"
+ ><p
+ >A hash table with keys of type <code
+ >key</code
+ > and values of type <code
+ >val</code
+ >.
+ The type <code
+ >key</code
+ > should be an instance of <code
+ ><a href=""
+ >Eq</a
+ ></code
+ >.
+</p
+ ></div
+ ></div
+ ><h2 id="g:2"
+ >Operations on <code
+ >HashTable</code
+ >s
+</h2
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:new" class="def"
+ >new</a
+ > :: (<a href=""
+ >Eq</a
+ > key, <a href=""
+ >Hash</a
+ > key) =&gt; <a href=""
+ >Int</a
+ > -&gt; <a href=""
+ >IO</a
+ > (<a href=""
+ >HashTable</a
+ > key val)</p
+ ><div class="doc"
+ ><p
+ >Builds a new hash table with a given size
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:insert" class="def"
+ >insert</a
+ > :: (<a href=""
+ >Eq</a
+ > key, <a href=""
+ >Hash</a
+ > key) =&gt; key -&gt; val -&gt; <a href=""
+ >IO</a
+ > ()</p
+ ><div class="doc"
+ ><p
+ >Inserts a new element into the hash table
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:lookup" class="def"
+ >lookup</a
+ > :: <a href=""
+ >Hash</a
+ > key =&gt; key -&gt; <a href=""
+ >IO</a
+ > (<a href=""
+ >Maybe</a
+ > val)</p
+ ><div class="doc"
+ ><p
+ >Looks up a key in the hash table, returns <code
+ ><code
+ ><a href=""
+ >Just</a
+ ></code
+ > val</code
+ > if the key
+ was found, or <code
+ ><a href=""
+ >Nothing</a
+ ></code
+ > otherwise.
+</p
+ ></div
+ ></div
+ ><h1 id="g:3"
+ >The <code
+ >Hash</code
+ > class
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a name="t:Hash" class="def"
+ >Hash</a
+ > a <span class="keyword"
+ >where</span
+ ></p
+ ><div class="doc"
+ ><p
+ >A class of types which can be hashed.
+</p
+ ></div
+ ><div class="subs methods"
+ ><p class="caption"
+ >Methods</p
+ ><p class="src"
+ ><a name="v:hash" class="def"
+ >hash</a
+ > :: a -&gt; <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >hashes the value of type <code
+ >a</code
+ > into an <code
+ ><a href=""
+ >Int</a
+ ></code
+ >
+</p
+ ></div
+ ></div
+ ><div class="subs instances"
+ ><p id="control.i:Hash" class="caption collapser" onclick="toggleSection('i:Hash')"
+ >Instances</p
+ ><div id="section.i:Hash" class="show"
+ ><table
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >Hash</a
+ > <a href=""
+ >Float</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >Hash</a
+ > <a href=""
+ >Int</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ >(<a href=""
+ >Hash</a
+ > a, <a href=""
+ >Hash</a
+ > b) =&gt; <a href=""
+ >Hash</a
+ > (a, b)</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/HiddenInstances.html b/html-test/ref/HiddenInstances.html
new file mode 100644
index 00000000..4004a650
--- /dev/null
+++ b/html-test/ref/HiddenInstances.html
@@ -0,0 +1,169 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >HiddenInstances</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_HiddenInstances.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >HiddenInstances</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >class</span
+ > <a href=""
+ >VisibleClass</a
+ > a </li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >VisibleData</a
+ > </li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a name="t:VisibleClass" class="def"
+ >VisibleClass</a
+ > a </p
+ ><div class="doc"
+ ><p
+ >Should be visible
+</p
+ ></div
+ ><div class="subs instances"
+ ><p id="control.i:VisibleClass" class="caption collapser" onclick="toggleSection('i:VisibleClass')"
+ >Instances</p
+ ><div id="section.i:VisibleClass" class="show"
+ ><table
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >VisibleClass</a
+ > <a href=""
+ >Int</a
+ ></td
+ ><td class="doc"
+ ><p
+ >Should be visible
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >VisibleClass</a
+ > <a href=""
+ >VisibleData</a
+ ></td
+ ><td class="doc"
+ ><p
+ >Should be visible
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:VisibleData" class="def"
+ >VisibleData</a
+ > </p
+ ><div class="doc"
+ ><p
+ >Should be visible
+</p
+ ></div
+ ><div class="subs instances"
+ ><p id="control.i:VisibleData" class="caption collapser" onclick="toggleSection('i:VisibleData')"
+ >Instances</p
+ ><div id="section.i:VisibleData" class="show"
+ ><table
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >Num</a
+ > <a href=""
+ >VisibleData</a
+ ></td
+ ><td class="doc"
+ ><p
+ >Should be visible
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >VisibleClass</a
+ > <a href=""
+ >VisibleData</a
+ ></td
+ ><td class="doc"
+ ><p
+ >Should be visible
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/HiddenInstancesB.html b/html-test/ref/HiddenInstancesB.html
new file mode 100644
index 00000000..2a0bdf32
--- /dev/null
+++ b/html-test/ref/HiddenInstancesB.html
@@ -0,0 +1,143 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >HiddenInstancesB</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_HiddenInstancesB.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >HiddenInstancesB</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >class</span
+ > <a href=""
+ >Foo</a
+ > a </li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >Bar</a
+ > </li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a name="t:Foo" class="def"
+ >Foo</a
+ > a </p
+ ><div class="doc"
+ ><p
+ >Should be visible
+</p
+ ></div
+ ><div class="subs instances"
+ ><p id="control.i:Foo" class="caption collapser" onclick="toggleSection('i:Foo')"
+ >Instances</p
+ ><div id="section.i:Foo" class="show"
+ ><table
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >Foo</a
+ > <a href=""
+ >Bar</a
+ ></td
+ ><td class="doc"
+ ><p
+ >Should be visible
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:Bar" class="def"
+ >Bar</a
+ > </p
+ ><div class="doc"
+ ><p
+ >Should be visible
+</p
+ ></div
+ ><div class="subs instances"
+ ><p id="control.i:Bar" class="caption collapser" onclick="toggleSection('i:Bar')"
+ >Instances</p
+ ><div id="section.i:Bar" class="show"
+ ><table
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >Foo</a
+ > <a href=""
+ >Bar</a
+ ></td
+ ><td class="doc"
+ ><p
+ >Should be visible
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Hyperlinks.html b/html-test/ref/Hyperlinks.html
new file mode 100644
index 00000000..6224c9b5
--- /dev/null
+++ b/html-test/ref/Hyperlinks.html
@@ -0,0 +1,89 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Hyperlinks</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Hyperlinks.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Hyperlinks</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >A plain URL: <a href=""
+ >http://example.com/</a
+ >
+</p
+ ><p
+ >A URL with a label: <a href=""
+ >some link</a
+ >
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/IgnoreExports.html b/html-test/ref/IgnoreExports.html
new file mode 100644
index 00000000..15a081fd
--- /dev/null
+++ b/html-test/ref/IgnoreExports.html
@@ -0,0 +1,101 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >IgnoreExports</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_IgnoreExports.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >IgnoreExports</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >bar</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >documentation for foo
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:bar" class="def"
+ >bar</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >documentation for bar
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/ModuleWithWarning.html b/html-test/ref/ModuleWithWarning.html
new file mode 100644
index 00000000..97120c60
--- /dev/null
+++ b/html-test/ref/ModuleWithWarning.html
@@ -0,0 +1,83 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >ModuleWithWarning</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_ModuleWithWarning.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >ModuleWithWarning</p
+ ></div
+ ><div id="description"
+ ><p class="caption"
+ >Description</p
+ ><div class="doc"
+ ><div class="warning"
+ ><p
+ >Warning: This is an unstable interface. Prefer functions from <a href=""
+ >Prelude</a
+ > instead!
+</p
+ ></div
+ ><p
+ >Documentation for <a href=""
+ >ModuleWithWarning</a
+ >.
+</p
+ ></div
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:foo" class="def"
+ >foo</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/NamedDoc.html b/html-test/ref/NamedDoc.html
new file mode 100644
index 00000000..9974486b
--- /dev/null
+++ b/html-test/ref/NamedDoc.html
@@ -0,0 +1,68 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >NamedDoc</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_NamedDoc.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >NamedDoc</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="doc"
+ ><p
+ >bar
+</p
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/NoLayout.html b/html-test/ref/NoLayout.html
new file mode 100644
index 00000000..e0e6d2cd
--- /dev/null
+++ b/html-test/ref/NoLayout.html
@@ -0,0 +1,86 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >NoLayout</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_NoLayout.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >NoLayout</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >g</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:g" class="def"
+ >g</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >the function <code
+ ><a href=""
+ >g</a
+ ></code
+ >
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/NonGreedy.html b/html-test/ref/NonGreedy.html
new file mode 100644
index 00000000..4b7d60e1
--- /dev/null
+++ b/html-test/ref/NonGreedy.html
@@ -0,0 +1,82 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >NonGreedy</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_NonGreedy.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >NonGreedy</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >f</a
+ > :: a</li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:f" class="def"
+ >f</a
+ > :: a</p
+ ><div class="doc"
+ ><p
+ ><a href=""
+ >url1</a
+ > <a href=""
+ >url2</a
+ >
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Properties.html b/html-test/ref/Properties.html
new file mode 100644
index 00000000..a12c4c78
--- /dev/null
+++ b/html-test/ref/Properties.html
@@ -0,0 +1,92 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Properties</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Properties.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Properties</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >fib</a
+ > :: <a href=""
+ >Integer</a
+ > -&gt; <a href=""
+ >Integer</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:fib" class="def"
+ >fib</a
+ > :: <a href=""
+ >Integer</a
+ > -&gt; <a href=""
+ >Integer</a
+ ></p
+ ><div class="doc"
+ ><p
+ >Fibonacci number of given <code
+ ><a href=""
+ >Integer</a
+ ></code
+ >.
+</p
+ ><pre
+ >fib n &lt;= fib (n + 1)</pre
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/PruneWithWarning.html b/html-test/ref/PruneWithWarning.html
new file mode 100644
index 00000000..b84bca9b
--- /dev/null
+++ b/html-test/ref/PruneWithWarning.html
@@ -0,0 +1,72 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >PruneWithWarning</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_PruneWithWarning.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >PruneWithWarning</p
+ ></div
+ ><div id="description"
+ ><p class="caption"
+ >Description</p
+ ><div class="doc"
+ ><p
+ >What is tested here:
+</p
+ ><ul
+ ><li
+ > If a binding has a deprecation message but no documentation, it is pruned
+ when <code
+ >OPTIONS_HADDOCK prune</code
+ > is used.
+</li
+ ></ul
+ ></div
+ ></div
+ ><div id="interface"
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/QuasiExpr.html b/html-test/ref/QuasiExpr.html
new file mode 100644
index 00000000..b6c24d0b
--- /dev/null
+++ b/html-test/ref/QuasiExpr.html
@@ -0,0 +1,221 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >QuasiExpr</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_QuasiExpr.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >QuasiExpr</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:Expr" class="def"
+ >Expr</a
+ > </p
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:IntExpr" class="def"
+ >IntExpr</a
+ > <a href=""
+ >Integer</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:AntiIntExpr" class="def"
+ >AntiIntExpr</a
+ > <a href=""
+ >String</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:BinopExpr" class="def"
+ >BinopExpr</a
+ > <a href=""
+ >BinOp</a
+ > <a href=""
+ >Expr</a
+ > <a href=""
+ >Expr</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:AntiExpr" class="def"
+ >AntiExpr</a
+ > <a href=""
+ >String</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ><div class="subs instances"
+ ><p id="control.i:Expr" class="caption collapser" onclick="toggleSection('i:Expr')"
+ >Instances</p
+ ><div id="section.i:Expr" class="show"
+ ><table
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >Show</a
+ > <a href=""
+ >Expr</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:BinOp" class="def"
+ >BinOp</a
+ > </p
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:AddOp" class="def"
+ >AddOp</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:SubOp" class="def"
+ >SubOp</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:MulOp" class="def"
+ >MulOp</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:DivOp" class="def"
+ >DivOp</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ><div class="subs instances"
+ ><p id="control.i:BinOp" class="caption collapser" onclick="toggleSection('i:BinOp')"
+ >Instances</p
+ ><div id="section.i:BinOp" class="show"
+ ><table
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >Show</a
+ > <a href=""
+ >BinOp</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:eval" class="def"
+ >eval</a
+ > :: <a href=""
+ >Expr</a
+ > -&gt; <a href=""
+ >Integer</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:expr" class="def"
+ >expr</a
+ > :: QuasiQuoter</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:parseExprExp" class="def"
+ >parseExprExp</a
+ > :: <a href=""
+ >String</a
+ > -&gt; Q Exp</p
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/QuasiQuote.html b/html-test/ref/QuasiQuote.html
new file mode 100644
index 00000000..c85cbcbd
--- /dev/null
+++ b/html-test/ref/QuasiQuote.html
@@ -0,0 +1,65 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >QuasiQuote</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_QuasiQuote.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >QuasiQuote</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:val" class="def"
+ >val</a
+ > :: <a href=""
+ >Integer</a
+ ></p
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/SpuriousSuperclassConstraints.html b/html-test/ref/SpuriousSuperclassConstraints.html
new file mode 100644
index 00000000..bc7184d0
--- /dev/null
+++ b/html-test/ref/SpuriousSuperclassConstraints.html
@@ -0,0 +1,128 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >SpuriousSuperclassConstraints</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_SpuriousSuperclassConstraints.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >SpuriousSuperclassConstraints</p
+ ></div
+ ><div id="description"
+ ><p class="caption"
+ >Description</p
+ ><div class="doc"
+ ><p
+ >What is tested here:
+</p
+ ><p
+ >Due to a change in GHC 7.6.1 we had a bug that superclass contraints were
+ included in the instances list. Edward K. repported it here:
+</p
+ ><p
+ ><a href=""
+ >http://www.haskell.org/pipermail/haskell-cafe/2012-September/103600.html</a
+ >
+</p
+ ><p
+ >And here is the corresponding theard on glasgow-haskell-users:
+</p
+ ><p
+ ><a href=""
+ >http://www.haskell.org/pipermail/glasgow-haskell-users/2012-September/022914.html</a
+ >
+</p
+ ><p
+ >It has been fixed in:
+</p
+ ><pre
+ > 6ccf78e15a525282fef61bc4f58a279aa9c21771
+ Fix spurious superclass constraints bug.
+</pre
+ ></div
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:SomeType" class="def"
+ >SomeType</a
+ > f a </p
+ ><div class="subs instances"
+ ><p id="control.i:SomeType" class="caption collapser" onclick="toggleSection('i:SomeType')"
+ >Instances</p
+ ><div id="section.i:SomeType" class="show"
+ ><table
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >Functor</a
+ > (<a href=""
+ >SomeType</a
+ > f)</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >Applicative</a
+ > f =&gt; <a href=""
+ >Applicative</a
+ > (<a href=""
+ >SomeType</a
+ > f)</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/TH.html b/html-test/ref/TH.html
new file mode 100644
index 00000000..8d02c280
--- /dev/null
+++ b/html-test/ref/TH.html
@@ -0,0 +1,63 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >TH</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_TH.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >TH</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:decl" class="def"
+ >decl</a
+ > :: Q [Dec]</p
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/TH2.html b/html-test/ref/TH2.html
new file mode 100644
index 00000000..7ef0ffe5
--- /dev/null
+++ b/html-test/ref/TH2.html
@@ -0,0 +1,63 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >TH2</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_TH2.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >TH2</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:f" class="def"
+ >f</a
+ > :: t -&gt; t</p
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Test.html b/html-test/ref/Test.html
new file mode 100644
index 00000000..55fdc6fc
--- /dev/null
+++ b/html-test/ref/Test.html
@@ -0,0 +1,2245 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Test</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Test.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Portability</th
+ ><td
+ >portable</td
+ ></tr
+ ><tr
+ ><th
+ >Stability</th
+ ><td
+ >provisional</td
+ ></tr
+ ><tr
+ ><th
+ >Maintainer</th
+ ><td
+ >libraries@haskell.org</td
+ ></tr
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Test</p
+ ></div
+ ><div id="table-of-contents"
+ ><p class="caption"
+ >Contents</p
+ ><ul
+ ><li
+ ><a href=""
+ >Type declarations
+</a
+ ><ul
+ ><li
+ ><a href=""
+ >Data types
+</a
+ ></li
+ ><li
+ ><a href=""
+ >Records
+</a
+ ></li
+ ></ul
+ ></li
+ ><li
+ ><a href=""
+ >Class declarations
+</a
+ ></li
+ ><li
+ ><a href=""
+ >Function types
+</a
+ ></li
+ ><li
+ ><a href=""
+ >Auxiliary stuff
+</a
+ ></li
+ ><li
+ ><a href=""
+ >A hidden module
+</a
+ ></li
+ ><li
+ ><a href=""
+ >A visible module
+</a
+ ></li
+ ><li
+ ><a href=""
+ >Existential / Universal types
+</a
+ ></li
+ ><li
+ ><a href=""
+ >Type signatures with argument docs
+</a
+ ></li
+ ><li
+ ><a href=""
+ >A section
+</a
+ ><ul
+ ><li
+ ><a href=""
+ >A subsection
+</a
+ ></li
+ ></ul
+ ></li
+ ></ul
+ ></div
+ ><div id="description"
+ ><p class="caption"
+ >Description</p
+ ><div class="doc"
+ ><p
+ >This module illustrates &amp; tests most of the features of Haddock.
+ Testing references from the description: <code
+ ><a href=""
+ >T</a
+ ></code
+ >, <code
+ ><a href=""
+ >f</a
+ ></code
+ >, <code
+ ><a href=""
+ >g</a
+ ></code
+ >, <code
+ ><a href=""
+ >visible</a
+ ></code
+ >.
+</p
+ ></div
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >T</a
+ > a b<ul class="subs"
+ ><li
+ >= <a href=""
+ >A</a
+ > <a href=""
+ >Int</a
+ > (<a href=""
+ >Maybe</a
+ > <a href=""
+ >Float</a
+ >) </li
+ ><li
+ >| <a href=""
+ >B</a
+ > (<a href=""
+ >T</a
+ > a b, <a href=""
+ >T</a
+ > <a href=""
+ >Int</a
+ > <a href=""
+ >Float</a
+ >) </li
+ ></ul
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >T2</a
+ > a b</li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >T3</a
+ > a b<ul class="subs"
+ ><li
+ >= <a href=""
+ >A1</a
+ > a </li
+ ><li
+ >| <a href=""
+ >B1</a
+ > b </li
+ ></ul
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >T4</a
+ > a b<ul class="subs"
+ ><li
+ >= <a href=""
+ >A2</a
+ > a </li
+ ><li
+ >| <a href=""
+ >B2</a
+ > b </li
+ ></ul
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >T5</a
+ > a b<ul class="subs"
+ ><li
+ >= <a href=""
+ >A3</a
+ > a </li
+ ><li
+ >| <a href=""
+ >B3</a
+ > b </li
+ ></ul
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >T6</a
+ > <ul class="subs"
+ ><li
+ >= <a href=""
+ >A4</a
+ > </li
+ ><li
+ >| <a href=""
+ >B4</a
+ > </li
+ ><li
+ >| <a href=""
+ >C4</a
+ > </li
+ ></ul
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >newtype</span
+ > <a href=""
+ >N1</a
+ > a = <a href=""
+ >N1</a
+ > a</li
+ ><li class="src short"
+ ><span class="keyword"
+ >newtype</span
+ > <a href=""
+ >N2</a
+ > a b = <a href=""
+ >N2</a
+ > {<ul class="subs"
+ ><li
+ ><a href=""
+ >n</a
+ > :: a b</li
+ ></ul
+ >}</li
+ ><li class="src short"
+ ><span class="keyword"
+ >newtype</span
+ > <a href=""
+ >N3</a
+ > a b = <a href=""
+ >N3</a
+ > {<ul class="subs"
+ ><li
+ ><a href=""
+ >n3</a
+ > :: a b</li
+ ></ul
+ >}</li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >N4</a
+ > a b</li
+ ><li class="src short"
+ ><span class="keyword"
+ >newtype</span
+ > <a href=""
+ >N5</a
+ > a b = <a href=""
+ >N5</a
+ > {<ul class="subs"
+ ><li
+ ><a href=""
+ >n5</a
+ > :: a b</li
+ ></ul
+ >}</li
+ ><li class="src short"
+ ><span class="keyword"
+ >newtype</span
+ > <a href=""
+ >N6</a
+ > a b = <a href=""
+ >N6</a
+ > {<ul class="subs"
+ ><li
+ ><a href=""
+ >n6</a
+ > :: a b</li
+ ></ul
+ >}</li
+ ><li class="src short"
+ ><span class="keyword"
+ >newtype</span
+ > <a href=""
+ >N7</a
+ > a b = <a href=""
+ >N7</a
+ > {<ul class="subs"
+ ><li
+ ><a href=""
+ >n7</a
+ > :: a b</li
+ ></ul
+ >}</li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >R</a
+ > <ul class="subs"
+ ><li
+ >= <a href=""
+ >C1</a
+ > { <ul class="subs"
+ ><li
+ ><a href=""
+ >p</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li
+ ><a href=""
+ >q</a
+ > :: <span class="keyword"
+ >forall</span
+ > a. a -&gt; a</li
+ ><li
+ ><a href=""
+ >r</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li
+ ><a href=""
+ >s</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ > }</li
+ ><li
+ >| <a href=""
+ >C2</a
+ > { <ul class="subs"
+ ><li
+ ><a href=""
+ >t</a
+ > :: T1 -&gt; <a href=""
+ >T2</a
+ > <a href=""
+ >Int</a
+ > <a href=""
+ >Int</a
+ > -&gt; <a href=""
+ >T3</a
+ > <a href=""
+ >Bool</a
+ > <a href=""
+ >Bool</a
+ > -&gt; <a href=""
+ >T4</a
+ > <a href=""
+ >Float</a
+ > <a href=""
+ >Float</a
+ > -&gt; <a href=""
+ >T5</a
+ > () ()</li
+ ><li
+ ><a href=""
+ >u</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li
+ ><a href=""
+ >v</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ > }</li
+ ></ul
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >R1</a
+ > = <a href=""
+ >C3</a
+ > {<ul class="subs"
+ ><li
+ ><a href=""
+ >s1</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li
+ ><a href=""
+ >s2</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li
+ ><a href=""
+ >s3</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ >}</li
+ ><li class="src short"
+ ><span class="keyword"
+ >class</span
+ > <a href=""
+ >D</a
+ > a =&gt; <a href=""
+ >C</a
+ > a <span class="keyword"
+ >where</span
+ ><ul class="subs"
+ ><li
+ ><a href=""
+ >a</a
+ > :: <a href=""
+ >IO</a
+ > a</li
+ ><li
+ ><a href=""
+ >b</a
+ > :: [a]</li
+ ></ul
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >class</span
+ > <a href=""
+ >D</a
+ > a <span class="keyword"
+ >where</span
+ ><ul class="subs"
+ ><li
+ ><a href=""
+ >d</a
+ > :: <a href=""
+ >T</a
+ > a b</li
+ ><li
+ ><a href=""
+ >e</a
+ > :: (a, a)</li
+ ></ul
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >class</span
+ > <a href=""
+ >E</a
+ > a </li
+ ><li class="src short"
+ ><span class="keyword"
+ >class</span
+ > <a href=""
+ >F</a
+ > a <span class="keyword"
+ >where</span
+ ><ul class="subs"
+ ><li
+ ><a href=""
+ >ff</a
+ > :: a</li
+ ></ul
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >f</a
+ > :: <a href=""
+ >C</a
+ > a =&gt; a -&gt; <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >g</a
+ > :: <a href=""
+ >Int</a
+ > -&gt; <a href=""
+ >IO</a
+ > CInt</li
+ ><li class="src short"
+ ><a href=""
+ >hidden</a
+ > :: <a href=""
+ >Int</a
+ > -&gt; <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ >module <a href=""
+ >Visible</a
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >Ex</a
+ > a<ul class="subs"
+ ><li
+ >= <span class="keyword"
+ >forall</span
+ > b . <a href=""
+ >C</a
+ > b =&gt; <a href=""
+ >Ex1</a
+ > b </li
+ ><li
+ >| <span class="keyword"
+ >forall</span
+ > b . <a href=""
+ >Ex2</a
+ > b </li
+ ><li
+ >| <span class="keyword"
+ >forall</span
+ > b . <a href=""
+ >C</a
+ > a =&gt; <a href=""
+ >Ex3</a
+ > b </li
+ ><li
+ >| <a href=""
+ >Ex4</a
+ > (<span class="keyword"
+ >forall</span
+ > a. a -&gt; a) </li
+ ></ul
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >k</a
+ > :: <a href=""
+ >T</a
+ > () () -&gt; <a href=""
+ >T2</a
+ > <a href=""
+ >Int</a
+ > <a href=""
+ >Int</a
+ > -&gt; (<a href=""
+ >T3</a
+ > <a href=""
+ >Bool</a
+ > <a href=""
+ >Bool</a
+ > -&gt; <a href=""
+ >T4</a
+ > <a href=""
+ >Float</a
+ > <a href=""
+ >Float</a
+ >) -&gt; <a href=""
+ >T5</a
+ > () () -&gt; <a href=""
+ >IO</a
+ > ()</li
+ ><li class="src short"
+ ><a href=""
+ >l</a
+ > :: (<a href=""
+ >Int</a
+ >, <a href=""
+ >Int</a
+ >, <a href=""
+ >Float</a
+ >) -&gt; <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >m</a
+ > :: <a href=""
+ >R</a
+ > -&gt; <a href=""
+ >N1</a
+ > () -&gt; <a href=""
+ >IO</a
+ > <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >o</a
+ > :: <a href=""
+ >Float</a
+ > -&gt; <a href=""
+ >IO</a
+ > <a href=""
+ >Float</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >f'</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >withType</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >withoutType</a
+ > :: a</li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1 id="g:1"
+ >Type declarations
+</h1
+ ><h2 id="g:2"
+ >Data types
+</h2
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:T" class="def"
+ >T</a
+ > a b </p
+ ><div class="doc"
+ ><p
+ >This comment applies to the <em
+ >following</em
+ > declaration
+ and it continues until the next non-comment line
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:A" class="def"
+ >A</a
+ > <a href=""
+ >Int</a
+ > (<a href=""
+ >Maybe</a
+ > <a href=""
+ >Float</a
+ >)</td
+ ><td class="doc"
+ ><p
+ >This comment describes the <code
+ ><a href=""
+ >A</a
+ ></code
+ > constructor
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:B" class="def"
+ >B</a
+ > (<a href=""
+ >T</a
+ > a b, <a href=""
+ >T</a
+ > <a href=""
+ >Int</a
+ > <a href=""
+ >Float</a
+ >)</td
+ ><td class="doc"
+ ><p
+ >This comment describes the <code
+ ><a href=""
+ >B</a
+ ></code
+ > constructor
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:T2" class="def"
+ >T2</a
+ > a b </p
+ ><div class="doc"
+ ><p
+ >An abstract data declaration
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:T3" class="def"
+ >T3</a
+ > a b </p
+ ><div class="doc"
+ ><p
+ >A data declaration with no documentation annotations on the constructors
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:A1" class="def"
+ >A1</a
+ > a</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:B1" class="def"
+ >B1</a
+ > b</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:T4" class="def"
+ >T4</a
+ > a b </p
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:A2" class="def"
+ >A2</a
+ > a</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:B2" class="def"
+ >B2</a
+ > b</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:T5" class="def"
+ >T5</a
+ > a b </p
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:A3" class="def"
+ >A3</a
+ > a</td
+ ><td class="doc"
+ ><p
+ >documents <code
+ ><a href=""
+ >A3</a
+ ></code
+ >
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:B3" class="def"
+ >B3</a
+ > b</td
+ ><td class="doc"
+ ><p
+ >documents <code
+ ><a href=""
+ >B3</a
+ ></code
+ >
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:T6" class="def"
+ >T6</a
+ > </p
+ ><div class="doc"
+ ><p
+ >Testing alternative comment styles
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:A4" class="def"
+ >A4</a
+ ></td
+ ><td class="doc"
+ ><p
+ >This is the doc for <code
+ ><a href=""
+ >A4</a
+ ></code
+ >
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:B4" class="def"
+ >B4</a
+ ></td
+ ><td class="doc"
+ ><p
+ >This is the doc for <code
+ ><a href=""
+ >B4</a
+ ></code
+ >
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:C4" class="def"
+ >C4</a
+ ></td
+ ><td class="doc"
+ ><p
+ >This is the doc for <code
+ ><a href=""
+ >C4</a
+ ></code
+ >
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >newtype</span
+ > <a name="t:N1" class="def"
+ >N1</a
+ > a </p
+ ><div class="doc"
+ ><p
+ >A newtype
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:N1" class="def"
+ >N1</a
+ > a</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >newtype</span
+ > <a name="t:N2" class="def"
+ >N2</a
+ > a b </p
+ ><div class="doc"
+ ><p
+ >A newtype with a fieldname
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:N2" class="def"
+ >N2</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td colspan="2"
+ ><div class="subs fields"
+ ><p class="caption"
+ >Fields</p
+ ><dl
+ ><dt class="src"
+ ><a name="v:n" class="def"
+ >n</a
+ > :: a b</dt
+ ><dd class="doc empty"
+ >&nbsp;</dd
+ ></dl
+ ><div class="clear"
+ ></div
+ ></div
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >newtype</span
+ > <a name="t:N3" class="def"
+ >N3</a
+ > a b </p
+ ><div class="doc"
+ ><p
+ >A newtype with a fieldname, documentation on the field
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:N3" class="def"
+ >N3</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td colspan="2"
+ ><div class="subs fields"
+ ><p class="caption"
+ >Fields</p
+ ><dl
+ ><dt class="src"
+ ><a name="v:n3" class="def"
+ >n3</a
+ > :: a b</dt
+ ><dd class="doc"
+ ><p
+ >this is the <code
+ ><a href=""
+ >n3</a
+ ></code
+ > field
+</p
+ ></dd
+ ></dl
+ ><div class="clear"
+ ></div
+ ></div
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:N4" class="def"
+ >N4</a
+ > a b </p
+ ><div class="doc"
+ ><p
+ >An abstract newtype - we show this one as data rather than newtype because
+ the difference isn't visible to the programmer for an abstract type.
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >newtype</span
+ > <a name="t:N5" class="def"
+ >N5</a
+ > a b </p
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:N5" class="def"
+ >N5</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td colspan="2"
+ ><div class="subs fields"
+ ><p class="caption"
+ >Fields</p
+ ><dl
+ ><dt class="src"
+ ><a name="v:n5" class="def"
+ >n5</a
+ > :: a b</dt
+ ><dd class="doc"
+ ><p
+ >no docs on the datatype or the constructor
+</p
+ ></dd
+ ></dl
+ ><div class="clear"
+ ></div
+ ></div
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >newtype</span
+ > <a name="t:N6" class="def"
+ >N6</a
+ > a b </p
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:N6" class="def"
+ >N6</a
+ ></td
+ ><td class="doc"
+ ><p
+ >docs on the constructor only
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td colspan="2"
+ ><div class="subs fields"
+ ><p class="caption"
+ >Fields</p
+ ><dl
+ ><dt class="src"
+ ><a name="v:n6" class="def"
+ >n6</a
+ > :: a b</dt
+ ><dd class="doc empty"
+ >&nbsp;</dd
+ ></dl
+ ><div class="clear"
+ ></div
+ ></div
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >newtype</span
+ > <a name="t:N7" class="def"
+ >N7</a
+ > a b </p
+ ><div class="doc"
+ ><p
+ >docs on the newtype and the constructor
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:N7" class="def"
+ >N7</a
+ ></td
+ ><td class="doc"
+ ><p
+ >The <code
+ ><a href=""
+ >N7</a
+ ></code
+ > constructor
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td colspan="2"
+ ><div class="subs fields"
+ ><p class="caption"
+ >Fields</p
+ ><dl
+ ><dt class="src"
+ ><a name="v:n7" class="def"
+ >n7</a
+ > :: a b</dt
+ ><dd class="doc empty"
+ >&nbsp;</dd
+ ></dl
+ ><div class="clear"
+ ></div
+ ></div
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><h2 id="g:3"
+ >Records
+</h2
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:R" class="def"
+ >R</a
+ > </p
+ ><div class="doc"
+ ><p
+ >This is the documentation for the <code
+ ><a href=""
+ >R</a
+ ></code
+ > record, which has four fields,
+ <code
+ ><a href=""
+ >p</a
+ ></code
+ >, <code
+ ><a href=""
+ >q</a
+ ></code
+ >, <code
+ ><a href=""
+ >r</a
+ ></code
+ >, and <code
+ ><a href=""
+ >s</a
+ ></code
+ >.
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:C1" class="def"
+ >C1</a
+ ></td
+ ><td class="doc"
+ ><p
+ >This is the <code
+ ><a href=""
+ >C1</a
+ ></code
+ > record constructor, with the following fields:
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td colspan="2"
+ ><div class="subs fields"
+ ><p class="caption"
+ >Fields</p
+ ><dl
+ ><dt class="src"
+ ><a name="v:p" class="def"
+ >p</a
+ > :: <a href=""
+ >Int</a
+ ></dt
+ ><dd class="doc"
+ ><p
+ >This comment applies to the <code
+ ><a href=""
+ >p</a
+ ></code
+ > field
+</p
+ ></dd
+ ><dt class="src"
+ ><a name="v:q" class="def"
+ >q</a
+ > :: <span class="keyword"
+ >forall</span
+ > a. a -&gt; a</dt
+ ><dd class="doc"
+ ><p
+ >This comment applies to the <code
+ ><a href=""
+ >q</a
+ ></code
+ > field
+</p
+ ></dd
+ ><dt class="src"
+ ><a name="v:r" class="def"
+ >r</a
+ > :: <a href=""
+ >Int</a
+ ></dt
+ ><dd class="doc"
+ ><p
+ >This comment applies to both <code
+ ><a href=""
+ >r</a
+ ></code
+ > and <code
+ ><a href=""
+ >s</a
+ ></code
+ >
+</p
+ ></dd
+ ><dt class="src"
+ ><a name="v:s" class="def"
+ >s</a
+ > :: <a href=""
+ >Int</a
+ ></dt
+ ><dd class="doc"
+ ><p
+ >This comment applies to both <code
+ ><a href=""
+ >r</a
+ ></code
+ > and <code
+ ><a href=""
+ >s</a
+ ></code
+ >
+</p
+ ></dd
+ ></dl
+ ><div class="clear"
+ ></div
+ ></div
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:C2" class="def"
+ >C2</a
+ ></td
+ ><td class="doc"
+ ><p
+ >This is the <code
+ ><a href=""
+ >C2</a
+ ></code
+ > record constructor, also with some fields:
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td colspan="2"
+ ><div class="subs fields"
+ ><p class="caption"
+ >Fields</p
+ ><dl
+ ><dt class="src"
+ ><a name="v:t" class="def"
+ >t</a
+ > :: T1 -&gt; <a href=""
+ >T2</a
+ > <a href=""
+ >Int</a
+ > <a href=""
+ >Int</a
+ > -&gt; <a href=""
+ >T3</a
+ > <a href=""
+ >Bool</a
+ > <a href=""
+ >Bool</a
+ > -&gt; <a href=""
+ >T4</a
+ > <a href=""
+ >Float</a
+ > <a href=""
+ >Float</a
+ > -&gt; <a href=""
+ >T5</a
+ > () ()</dt
+ ><dd class="doc empty"
+ >&nbsp;</dd
+ ><dt class="src"
+ ><a name="v:u" class="def"
+ >u</a
+ > :: <a href=""
+ >Int</a
+ ></dt
+ ><dd class="doc empty"
+ >&nbsp;</dd
+ ><dt class="src"
+ ><a name="v:v" class="def"
+ >v</a
+ > :: <a href=""
+ >Int</a
+ ></dt
+ ><dd class="doc empty"
+ >&nbsp;</dd
+ ></dl
+ ><div class="clear"
+ ></div
+ ></div
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:R1" class="def"
+ >R1</a
+ > </p
+ ><div class="doc"
+ ><p
+ >Testing different record commenting styles
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:C3" class="def"
+ >C3</a
+ ></td
+ ><td class="doc"
+ ><p
+ >This is the <code
+ ><a href=""
+ >C3</a
+ ></code
+ > record constructor
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td colspan="2"
+ ><div class="subs fields"
+ ><p class="caption"
+ >Fields</p
+ ><dl
+ ><dt class="src"
+ ><a name="v:s1" class="def"
+ >s1</a
+ > :: <a href=""
+ >Int</a
+ ></dt
+ ><dd class="doc"
+ ><p
+ >The <code
+ ><a href=""
+ >s1</a
+ ></code
+ > record selector
+</p
+ ></dd
+ ><dt class="src"
+ ><a name="v:s2" class="def"
+ >s2</a
+ > :: <a href=""
+ >Int</a
+ ></dt
+ ><dd class="doc"
+ ><p
+ >The <code
+ ><a href=""
+ >s2</a
+ ></code
+ > record selector
+</p
+ ></dd
+ ><dt class="src"
+ ><a name="v:s3" class="def"
+ >s3</a
+ > :: <a href=""
+ >Int</a
+ ></dt
+ ><dd class="doc"
+ ><p
+ >The <code
+ ><a href=""
+ >s3</a
+ ></code
+ > record selector
+</p
+ ></dd
+ ></dl
+ ><div class="clear"
+ ></div
+ ></div
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="doc"
+ ><p
+ >test that we can export record selectors on their own:
+</p
+ ></div
+ ><h1 id="g:4"
+ >Class declarations
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a href=""
+ >D</a
+ > a =&gt; <a name="t:C" class="def"
+ >C</a
+ > a <span class="keyword"
+ >where</span
+ ></p
+ ><div class="doc"
+ ><p
+ >This comment applies to the <em
+ >previous</em
+ > declaration (the <code
+ ><a href=""
+ >C</a
+ ></code
+ > class)
+</p
+ ></div
+ ><div class="subs methods"
+ ><p class="caption"
+ >Methods</p
+ ><p class="src"
+ ><a name="v:a" class="def"
+ >a</a
+ > :: <a href=""
+ >IO</a
+ > a</p
+ ><div class="doc"
+ ><p
+ >this is a description of the <code
+ ><a href=""
+ >a</a
+ ></code
+ > method
+</p
+ ></div
+ ><p class="src"
+ ><a name="v:b" class="def"
+ >b</a
+ > :: [a]</p
+ ><div class="doc"
+ ><p
+ >this is a description of the <code
+ ><a href=""
+ >b</a
+ ></code
+ > method
+</p
+ ></div
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a name="t:D" class="def"
+ >D</a
+ > a <span class="keyword"
+ >where</span
+ ></p
+ ><div class="doc"
+ ><p
+ >This is a class declaration with no separate docs for the methods
+</p
+ ></div
+ ><div class="subs methods"
+ ><p class="caption"
+ >Methods</p
+ ><p class="src"
+ ><a name="v:d" class="def"
+ >d</a
+ > :: <a href=""
+ >T</a
+ > a b</p
+ ><p class="src"
+ ><a name="v:e" class="def"
+ >e</a
+ > :: (a, a)</p
+ ></div
+ ><div class="subs instances"
+ ><p id="control.i:D" class="caption collapser" onclick="toggleSection('i:D')"
+ >Instances</p
+ ><div id="section.i:D" class="show"
+ ><table
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >D</a
+ > <a href=""
+ >Float</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >D</a
+ > <a href=""
+ >Int</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a name="t:E" class="def"
+ >E</a
+ > a </p
+ ><div class="doc"
+ ><p
+ >This is a class declaration with no methods (or no methods exported)
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a name="t:F" class="def"
+ >F</a
+ > a <span class="keyword"
+ >where</span
+ ></p
+ ><div class="subs methods"
+ ><p class="caption"
+ >Methods</p
+ ><p class="src"
+ ><a name="v:ff" class="def"
+ >ff</a
+ > :: a</p
+ ></div
+ ></div
+ ><div class="doc"
+ ><p
+ >Test that we can export a class method on its own:
+</p
+ ></div
+ ><h1 id="g:5"
+ >Function types
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:f" class="def"
+ >f</a
+ > :: <a href=""
+ >C</a
+ > a =&gt; a -&gt; <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >In a comment string we can refer to identifiers in scope with
+single quotes like this: <code
+ ><a href=""
+ >T</a
+ ></code
+ >, and we can refer to modules by
+using double quotes: <a href=""
+ >Foo</a
+ >. We can add emphasis <em
+ >like this</em
+ >.
+</p
+ ><ul
+ ><li
+ > This is a bulleted list
+</li
+ ><li
+ > This is the next item (different kind of bullet)
+</li
+ ></ul
+ ><ol
+ ><li
+ > This is an ordered list
+</li
+ ><li
+ > This is the next item (different kind of bullet)
+</li
+ ></ol
+ ><dl
+ ><dt
+ >cat</dt
+ ><dd
+ > a small, furry, domesticated mammal
+</dd
+ ><dt
+ >pineapple</dt
+ ><dd
+ > a fruit grown in the tropics
+</dd
+ ></dl
+ ><pre
+ >
+ This is a block of code, which can include other markup: <code
+ ><a href=""
+ >R</a
+ ></code
+ >
+ formatting
+ is
+ significant
+</pre
+ ><pre
+ > this is another block of code
+</pre
+ ><p
+ >We can also include URLs in documentation: <a href=""
+ >http://www.haskell.org/</a
+ >.
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:g" class="def"
+ >g</a
+ > :: <a href=""
+ >Int</a
+ > -&gt; <a href=""
+ >IO</a
+ > CInt</p
+ ><div class="doc"
+ ><p
+ >we can export foreign declarations too
+</p
+ ></div
+ ></div
+ ><h1 id="g:6"
+ >Auxiliary stuff
+</h1
+ ><div class="doc"
+ ><p
+ >This is some documentation that is attached to a name ($aux1)
+ rather than a source declaration. The documentation may be
+ referred to in the export list using its name.
+</p
+ ><pre
+ > code block in named doc</pre
+ ></div
+ ><div class="doc"
+ ><p
+ >This is some documentation that is attached to a name ($aux2)
+</p
+ ></div
+ ><div class="doc"
+ ><pre
+ > code block on its own in named doc</pre
+ ></div
+ ><div class="doc"
+ ><pre
+ > code block on its own in named doc (after newline)</pre
+ ></div
+ ><div class="doc"
+ ><p
+ >a nested, named doc comment
+</p
+ ><p
+ >with a paragraph,
+</p
+ ><pre
+ > and a code block</pre
+ ></div
+ ><div class="doc"
+ ><pre
+ >test
+test1
+</pre
+ ><pre
+ > test2
+ test3
+</pre
+ ></div
+ ><div class="doc"
+ ><pre
+ >
+test1
+test2
+</pre
+ ></div
+ ><div class="doc"
+ ><pre
+ >test3
+test4
+</pre
+ ></div
+ ><div class="doc"
+ ><pre
+ >
+test1
+test2
+</pre
+ ><pre
+ >test3
+test4
+</pre
+ ></div
+ ><div class="doc"
+ ><pre
+ >test3
+test4
+</pre
+ ><pre
+ >
+test1
+test2
+</pre
+ ></div
+ ><div class="doc"
+ ><p
+ >aux11:
+</p
+ ><pre
+ >test3
+test4
+</pre
+ ><pre
+ >
+test1
+test2
+</pre
+ ></div
+ ><div class="doc"
+ ><pre
+ > foo
+</pre
+ ><pre
+ > bar
+</pre
+ ></div
+ ><div class="doc"
+ ><p
+ >This is some inline documentation in the export list
+</p
+ ><pre
+ > a code block using bird-tracks
+ each line must begin with &gt; (which isn't significant unless it
+ is at the beginning of the line).
+</pre
+ ></div
+ ><h1 id="g:7"
+ >A hidden module
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:hidden" class="def"
+ >hidden</a
+ > :: <a href=""
+ >Int</a
+ > -&gt; <a href=""
+ >Int</a
+ ></p
+ ></div
+ ><h1 id="g:8"
+ >A visible module
+</h1
+ ><div class="top"
+ ><p class="src"
+ >module <a href=""
+ >Visible</a
+ ></p
+ ></div
+ ><div class="doc"
+ ><p
+ >nested-style doc comments
+</p
+ ></div
+ ><h1 id="g:9"
+ >Existential / Universal types
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:Ex" class="def"
+ >Ex</a
+ > a </p
+ ><div class="doc"
+ ><p
+ >A data-type using existential/universal types
+</p
+ ></div
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><span class="keyword"
+ >forall</span
+ > b . <a href=""
+ >C</a
+ > b =&gt; <a name="v:Ex1" class="def"
+ >Ex1</a
+ > b</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><span class="keyword"
+ >forall</span
+ > b . <a name="v:Ex2" class="def"
+ >Ex2</a
+ > b</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><span class="keyword"
+ >forall</span
+ > b . <a href=""
+ >C</a
+ > a =&gt; <a name="v:Ex3" class="def"
+ >Ex3</a
+ > b</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ ><a name="v:Ex4" class="def"
+ >Ex4</a
+ > (<span class="keyword"
+ >forall</span
+ > a. a -&gt; a)</td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><h1 id="g:10"
+ >Type signatures with argument docs
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:k" class="def"
+ >k</a
+ ></p
+ ><div class="subs arguments"
+ ><p class="caption"
+ >Arguments</p
+ ><table
+ ><tr
+ ><td class="src"
+ >:: <a href=""
+ >T</a
+ > () ()</td
+ ><td class="doc"
+ ><p
+ >This argument has type <code
+ ><a href=""
+ >T</a
+ ></code
+ >
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; <a href=""
+ >T2</a
+ > <a href=""
+ >Int</a
+ > <a href=""
+ >Int</a
+ ></td
+ ><td class="doc"
+ ><p
+ >This argument has type 'T2 Int Int'
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; (<a href=""
+ >T3</a
+ > <a href=""
+ >Bool</a
+ > <a href=""
+ >Bool</a
+ > -&gt; <a href=""
+ >T4</a
+ > <a href=""
+ >Float</a
+ > <a href=""
+ >Float</a
+ >)</td
+ ><td class="doc"
+ ><p
+ >This argument has type <code
+ >T3 Bool Bool -&gt; T4 Float Float</code
+ >
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; <a href=""
+ >T5</a
+ > () ()</td
+ ><td class="doc"
+ ><p
+ >This argument has a very long description that should
+ hopefully cause some wrapping to happen when it is finally
+ rendered by Haddock in the generated HTML page.
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; <a href=""
+ >IO</a
+ > ()</td
+ ><td class="doc"
+ ><p
+ >This is the result type
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ><div class="doc"
+ ><p
+ >This is a function with documentation for each argument
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:l" class="def"
+ >l</a
+ ></p
+ ><div class="subs arguments"
+ ><p class="caption"
+ >Arguments</p
+ ><table
+ ><tr
+ ><td class="src"
+ >:: (<a href=""
+ >Int</a
+ >, <a href=""
+ >Int</a
+ >, <a href=""
+ >Float</a
+ >)</td
+ ><td class="doc"
+ ><p
+ >takes a triple
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; <a href=""
+ >Int</a
+ ></td
+ ><td class="doc"
+ ><p
+ >returns an <code
+ ><a href=""
+ >Int</a
+ ></code
+ >
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:m" class="def"
+ >m</a
+ ></p
+ ><div class="subs arguments"
+ ><p class="caption"
+ >Arguments</p
+ ><table
+ ><tr
+ ><td class="src"
+ >:: <a href=""
+ >R</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; <a href=""
+ >N1</a
+ > ()</td
+ ><td class="doc"
+ ><p
+ >one of the arguments
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; <a href=""
+ >IO</a
+ > <a href=""
+ >Int</a
+ ></td
+ ><td class="doc"
+ ><p
+ >and the return value
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ><div class="doc"
+ ><p
+ >This function has some arg docs
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:o" class="def"
+ >o</a
+ ></p
+ ><div class="subs arguments"
+ ><p class="caption"
+ >Arguments</p
+ ><table
+ ><tr
+ ><td class="src"
+ >:: <a href=""
+ >Float</a
+ ></td
+ ><td class="doc"
+ ><p
+ >The input float
+</p
+ ></td
+ ></tr
+ ><tr
+ ><td class="src"
+ >-&gt; <a href=""
+ >IO</a
+ > <a href=""
+ >Float</a
+ ></td
+ ><td class="doc"
+ ><p
+ >The output float
+</p
+ ></td
+ ></tr
+ ></table
+ ></div
+ ><div class="doc"
+ ><p
+ >A foreign import with argument docs
+</p
+ ></div
+ ></div
+ ><h1 id="g:11"
+ >A section
+</h1
+ ><h2 id="g:12"
+ >A subsection
+</h2
+ ><div class="doc"
+ ><pre
+ > a literal line
+</pre
+ ><p
+ >$ a non <em
+ >literal</em
+ > line $
+</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:f-39-" class="def"
+ >f'</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >a function with a prime can be referred to as <code
+ ><a href=""
+ >f'</a
+ ></code
+ >
+ but f' doesn't get link'd 'f\''
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:withType" class="def"
+ >withType</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >Comment on a definition with type signature
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:withoutType" class="def"
+ >withoutType</a
+ > :: a</p
+ ><div class="doc"
+ ><p
+ >Comment on a definition without type signature
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Ticket112.html b/html-test/ref/Ticket112.html
new file mode 100644
index 00000000..91aa3c90
--- /dev/null
+++ b/html-test/ref/Ticket112.html
@@ -0,0 +1,82 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Ticket112</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Ticket112.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Ticket112</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >f</a
+ > :: a</li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:f" class="def"
+ >f</a
+ > :: a</p
+ ><div class="doc"
+ ><p
+ >...given a raw <code
+ ><a href=""
+ >Addr#</a
+ ></code
+ > to the string, and the length of the string.
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Ticket61.html b/html-test/ref/Ticket61.html
new file mode 100644
index 00000000..41ec91ba
--- /dev/null
+++ b/html-test/ref/Ticket61.html
@@ -0,0 +1,80 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Ticket61</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Ticket61.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Ticket61</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a name="t:C" class="def"
+ >C</a
+ > a <span class="keyword"
+ >where</span
+ ></p
+ ><div class="subs methods"
+ ><p class="caption"
+ >Methods</p
+ ><p class="src"
+ ><a name="v:f" class="def"
+ >f</a
+ > :: a</p
+ ><div class="doc"
+ ><p
+ >A comment about f
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Ticket75.html b/html-test/ref/Ticket75.html
new file mode 100644
index 00000000..bfbbbc73
--- /dev/null
+++ b/html-test/ref/Ticket75.html
@@ -0,0 +1,116 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Ticket75</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Ticket75.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Ticket75</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > a <a href=""
+ >:-</a
+ > b = <a href=""
+ >Q</a
+ ></li
+ ><li class="src short"
+ ><a href=""
+ >f</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > a <a name="t::-45-" class="def"
+ >:-</a
+ > b </p
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:Q" class="def"
+ >Q</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:f" class="def"
+ >f</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >A reference to <code
+ ><a href=""
+ >:-</a
+ ></code
+ >
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/TypeFamilies.html b/html-test/ref/TypeFamilies.html
new file mode 100644
index 00000000..88efdee5
--- /dev/null
+++ b/html-test/ref/TypeFamilies.html
@@ -0,0 +1,212 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >TypeFamilies</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_TypeFamilies.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >TypeFamilies</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >type family</span
+ > <a href=""
+ >G</a
+ > a :: *</li
+ ><li class="src short"
+ ><span class="keyword"
+ >class</span
+ > <a href=""
+ >A</a
+ > a <span class="keyword"
+ >where</span
+ ><ul class="subs"
+ ><li
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >B</a
+ > a :: * -&gt; *</li
+ ><li
+ ><a href=""
+ >f</a
+ > :: <a href=""
+ >B</a
+ > a <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></li
+ ><li class="src short"
+ ><span class="keyword"
+ >type family</span
+ > <a href=""
+ >F</a
+ > a </li
+ ><li class="src short"
+ ><a href=""
+ >g</a
+ > :: <a href=""
+ >B</a
+ > <a href=""
+ >Int</a
+ > <a href=""
+ >Integer</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >type family</span
+ > <a name="t:G" class="def"
+ >G</a
+ > a :: *</p
+ ><div class="doc"
+ ><p
+ >Type family G
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a name="t:A" class="def"
+ >A</a
+ > a <span class="keyword"
+ >where</span
+ ></p
+ ><div class="doc"
+ ><p
+ >A class with an associated type
+</p
+ ></div
+ ><div class="subs associated-types"
+ ><p class="caption"
+ >Associated Types</p
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:B" class="def"
+ >B</a
+ > a :: * -&gt; *</p
+ ><div class="doc"
+ ><p
+ >An associated type
+</p
+ ></div
+ ></div
+ ><div class="subs methods"
+ ><p class="caption"
+ >Methods</p
+ ><p class="src"
+ ><a name="v:f" class="def"
+ >f</a
+ > :: <a href=""
+ >B</a
+ > a <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >A method
+</p
+ ></div
+ ></div
+ ><div class="subs instances"
+ ><p id="control.i:A" class="caption collapser" onclick="toggleSection('i:A')"
+ >Instances</p
+ ><div id="section.i:A" class="show"
+ ><table
+ ><tr
+ ><td class="src"
+ ><a href=""
+ >A</a
+ > <a href=""
+ >Int</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >type family</span
+ > <a name="t:F" class="def"
+ >F</a
+ > a </p
+ ><div class="doc"
+ ><p
+ >Doc for family
+</p
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:g" class="def"
+ >g</a
+ > :: <a href=""
+ >B</a
+ > <a href=""
+ >Int</a
+ > <a href=""
+ >Integer</a
+ ></p
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/TypeOperators.html b/html-test/ref/TypeOperators.html
new file mode 100644
index 00000000..8329bab2
--- /dev/null
+++ b/html-test/ref/TypeOperators.html
@@ -0,0 +1,185 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >TypeOperators</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_TypeOperators.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >TypeOperators</p
+ ></div
+ ><div id="table-of-contents"
+ ><p class="caption"
+ >Contents</p
+ ><ul
+ ><li
+ ><a href=""
+ >stuff
+</a
+ ></li
+ ></ul
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > a <a href=""
+ >:-:</a
+ > b</li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > (a <a href=""
+ >:+:</a
+ > b) c</li
+ ><li class="src short"
+ ><span class="keyword"
+ >data</span
+ > <a href=""
+ >Op</a
+ > a b</li
+ ><li class="src short"
+ ><span class="keyword"
+ >newtype</span
+ > <a href=""
+ >O</a
+ > g f a = <a href=""
+ >O</a
+ > {<ul class="subs"
+ ><li
+ ><a href=""
+ >unO</a
+ > :: g (f a)</li
+ ></ul
+ >}</li
+ ><li class="src short"
+ ><a href=""
+ >biO</a
+ > :: (g `<a href=""
+ >O</a
+ >` f) a</li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1 id="g:1"
+ >stuff
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > a <a name="t::-45-:" class="def"
+ >:-:</a
+ > b </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > (a <a name="t::-43-:" class="def"
+ >:+:</a
+ > b) c </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a name="t:Op" class="def"
+ >Op</a
+ > a b </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >newtype</span
+ > <a name="t:O" class="def"
+ >O</a
+ > g f a </p
+ ><div class="subs constructors"
+ ><p class="caption"
+ >Constructors</p
+ ><table
+ ><tr
+ ><td class="src"
+ ><a name="v:O" class="def"
+ >O</a
+ ></td
+ ><td class="doc empty"
+ >&nbsp;</td
+ ></tr
+ ><tr
+ ><td colspan="2"
+ ><div class="subs fields"
+ ><p class="caption"
+ >Fields</p
+ ><dl
+ ><dt class="src"
+ ><a name="v:unO" class="def"
+ >unO</a
+ > :: g (f a)</dt
+ ><dd class="doc empty"
+ >&nbsp;</dd
+ ></dl
+ ><div class="clear"
+ ></div
+ ></div
+ ></td
+ ></tr
+ ></table
+ ></div
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:biO" class="def"
+ >biO</a
+ > :: (g `<a href=""
+ >O</a
+ >` f) a</p
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Unicode.html b/html-test/ref/Unicode.html
new file mode 100644
index 00000000..110b0a7d
--- /dev/null
+++ b/html-test/ref/Unicode.html
@@ -0,0 +1,82 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Unicode</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Unicode.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Unicode</p
+ ></div
+ ><div id="synopsis"
+ ><p id="control.syn" class="caption expander" onclick="toggleSection('syn')"
+ >Synopsis</p
+ ><ul id="section.syn" class="hide" onclick="toggleSection('syn')"
+ ><li class="src short"
+ ><a href=""
+ >x</a
+ > :: <a href=""
+ >Int</a
+ ></li
+ ></ul
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:x" class="def"
+ >x</a
+ > :: <a href=""
+ >Int</a
+ ></p
+ ><div class="doc"
+ ><p
+ >&#947;&#955;&#974;&#963;&#963;&#945;
+</p
+ ></div
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/Visible.html b/html-test/ref/Visible.html
new file mode 100644
index 00000000..adbca598
--- /dev/null
+++ b/html-test/ref/Visible.html
@@ -0,0 +1,67 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Visible</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();setSynopsis("mini_Visible.html");};
+//]]>
+</script
+ ></head
+ ><body
+ ><div id="package-header"
+ ><ul class="links" id="page-menu"
+ ><li
+ ><a href=""
+ >Contents</a
+ ></li
+ ><li
+ ><a href=""
+ >Index</a
+ ></li
+ ></ul
+ ><p class="caption empty"
+ >&nbsp;</p
+ ></div
+ ><div id="content"
+ ><div id="module-header"
+ ><table class="info"
+ ><tr
+ ><th
+ >Safe Haskell</th
+ ><td
+ >None</td
+ ></tr
+ ></table
+ ><p class="caption"
+ >Visible</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >Documentation</h1
+ ><div class="top"
+ ><p class="src"
+ ><a name="v:visible" class="def"
+ >visible</a
+ > :: <a href=""
+ >Int</a
+ > -&gt; <a href=""
+ >Int</a
+ ></p
+ ></div
+ ></div
+ ></div
+ ><div id="footer"
+ ><p
+ >Produced by <a href=""
+ >Haddock</a
+ > version 2.13.2</p
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/frames.html b/html-test/ref/frames.html
new file mode 100644
index 00000000..1b4e38d4
--- /dev/null
+++ b/html-test/ref/frames.html
@@ -0,0 +1,30 @@
+<!DOCTYPE html
+ PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title></title>
+<script src="haddock-util.js" type="text/javascript"></script>
+<script type="text/javascript"><!--
+/*
+
+ The synopsis frame needs to be updated using javascript, so we hide
+ it by default and only show it if javascript is enabled.
+
+ TODO: provide some means to disable it.
+*/
+function load() {
+ var d = document.getElementById("inner-fs");
+ d.rows = "50%,50%";
+ postReframe();
+}
+--></script>
+</head>
+<frameset id="outer-fs" cols="25%,75%" onload="load()">
+ <frameset id="inner-fs" rows="100%,0%">
+ <frame src="index-frames.html" name="modules" />
+ <frame src="" name="synopsis" />
+ </frameset>
+ <frame src="index.html" name="main" />
+</frameset>
+</html>
diff --git a/html-test/ref/haddock-util.js b/html-test/ref/haddock-util.js
new file mode 100644
index 00000000..9a6fccf7
--- /dev/null
+++ b/html-test/ref/haddock-util.js
@@ -0,0 +1,344 @@
+// Haddock JavaScript utilities
+
+var rspace = /\s\s+/g,
+ rtrim = /^\s+|\s+$/g;
+
+function spaced(s) { return (" " + s + " ").replace(rspace, " "); }
+function trim(s) { return s.replace(rtrim, ""); }
+
+function hasClass(elem, value) {
+ var className = spaced(elem.className || "");
+ return className.indexOf( " " + value + " " ) >= 0;
+}
+
+function addClass(elem, value) {
+ var className = spaced(elem.className || "");
+ if ( className.indexOf( " " + value + " " ) < 0 ) {
+ elem.className = trim(className + " " + value);
+ }
+}
+
+function removeClass(elem, value) {
+ var className = spaced(elem.className || "");
+ className = className.replace(" " + value + " ", " ");
+ elem.className = trim(className);
+}
+
+function toggleClass(elem, valueOn, valueOff, bool) {
+ if (bool == null) { bool = ! hasClass(elem, valueOn); }
+ if (bool) {
+ removeClass(elem, valueOff);
+ addClass(elem, valueOn);
+ }
+ else {
+ removeClass(elem, valueOn);
+ addClass(elem, valueOff);
+ }
+ return bool;
+}
+
+
+function makeClassToggle(valueOn, valueOff)
+{
+ return function(elem, bool) {
+ return toggleClass(elem, valueOn, valueOff, bool);
+ }
+}
+
+toggleShow = makeClassToggle("show", "hide");
+toggleCollapser = makeClassToggle("collapser", "expander");
+
+function toggleSection(id)
+{
+ var b = toggleShow(document.getElementById("section." + id));
+ toggleCollapser(document.getElementById("control." + id), b);
+ rememberCollapsed(id, b);
+ return b;
+}
+
+var collapsed = {};
+function rememberCollapsed(id, b)
+{
+ if(b)
+ delete collapsed[id]
+ else
+ collapsed[id] = null;
+
+ var sections = [];
+ for(var i in collapsed)
+ {
+ if(collapsed.hasOwnProperty(i))
+ sections.push(i);
+ }
+ // cookie specific to this page; don't use setCookie which sets path=/
+ document.cookie = "collapsed=" + escape(sections.join('+'));
+}
+
+function restoreCollapsed()
+{
+ var cookie = getCookie("collapsed");
+ if(!cookie)
+ return;
+
+ var ids = cookie.split('+');
+ for(var i in ids)
+ {
+ if(document.getElementById("section." + ids[i]))
+ toggleSection(ids[i]);
+ }
+}
+
+function setCookie(name, value) {
+ document.cookie = name + "=" + escape(value) + ";path=/;";
+}
+
+function clearCookie(name) {
+ document.cookie = name + "=;path=/;expires=Thu, 01-Jan-1970 00:00:01 GMT;";
+}
+
+function getCookie(name) {
+ var nameEQ = name + "=";
+ var ca = document.cookie.split(';');
+ for(var i=0;i < ca.length;i++) {
+ var c = ca[i];
+ while (c.charAt(0)==' ') c = c.substring(1,c.length);
+ if (c.indexOf(nameEQ) == 0) {
+ return unescape(c.substring(nameEQ.length,c.length));
+ }
+ }
+ return null;
+}
+
+
+
+var max_results = 75; // 50 is not enough to search for map in the base libraries
+var shown_range = null;
+var last_search = null;
+
+function quick_search()
+{
+ perform_search(false);
+}
+
+function full_search()
+{
+ perform_search(true);
+}
+
+
+function perform_search(full)
+{
+ var text = document.getElementById("searchbox").value.toLowerCase();
+ if (text == last_search && !full) return;
+ last_search = text;
+
+ var table = document.getElementById("indexlist");
+ var status = document.getElementById("searchmsg");
+ var children = table.firstChild.childNodes;
+
+ // first figure out the first node with the prefix
+ var first = bisect(-1);
+ var last = (first == -1 ? -1 : bisect(1));
+
+ if (first == -1)
+ {
+ table.className = "";
+ status.innerHTML = "No results found, displaying all";
+ }
+ else if (first == 0 && last == children.length - 1)
+ {
+ table.className = "";
+ status.innerHTML = "";
+ }
+ else if (last - first >= max_results && !full)
+ {
+ table.className = "";
+ status.innerHTML = "More than " + max_results + ", press Search to display";
+ }
+ else
+ {
+ // decide what you need to clear/show
+ if (shown_range)
+ setclass(shown_range[0], shown_range[1], "indexrow");
+ setclass(first, last, "indexshow");
+ shown_range = [first, last];
+ table.className = "indexsearch";
+ status.innerHTML = "";
+ }
+
+
+ function setclass(first, last, status)
+ {
+ for (var i = first; i <= last; i++)
+ {
+ children[i].className = status;
+ }
+ }
+
+
+ // do a binary search, treating 0 as ...
+ // return either -1 (no 0's found) or location of most far match
+ function bisect(dir)
+ {
+ var first = 0, finish = children.length - 1;
+ var mid, success = false;
+
+ while (finish - first > 3)
+ {
+ mid = Math.floor((finish + first) / 2);
+
+ var i = checkitem(mid);
+ if (i == 0) i = dir;
+ if (i == -1)
+ finish = mid;
+ else
+ first = mid;
+ }
+ var a = (dir == 1 ? first : finish);
+ var b = (dir == 1 ? finish : first);
+ for (var i = b; i != a - dir; i -= dir)
+ {
+ if (checkitem(i) == 0) return i;
+ }
+ return -1;
+ }
+
+
+ // from an index, decide what the result is
+ // 0 = match, -1 is lower, 1 is higher
+ function checkitem(i)
+ {
+ var s = getitem(i).toLowerCase().substr(0, text.length);
+ if (s == text) return 0;
+ else return (s > text ? -1 : 1);
+ }
+
+
+ // from an index, get its string
+ // this abstracts over alternates
+ function getitem(i)
+ {
+ for ( ; i >= 0; i--)
+ {
+ var s = children[i].firstChild.firstChild.data;
+ if (s.indexOf(' ') == -1)
+ return s;
+ }
+ return ""; // should never be reached
+ }
+}
+
+function setSynopsis(filename) {
+ if (parent.window.synopsis) {
+ if (parent.window.synopsis.location.replace) {
+ // In Firefox this avoids adding the change to the history.
+ parent.window.synopsis.location.replace(filename);
+ } else {
+ parent.window.synopsis.location = filename;
+ }
+ }
+}
+
+function addMenuItem(html) {
+ var menu = document.getElementById("page-menu");
+ if (menu) {
+ var btn = menu.firstChild.cloneNode(false);
+ btn.innerHTML = html;
+ menu.appendChild(btn);
+ }
+}
+
+function adjustForFrames() {
+ var bodyCls;
+
+ if (parent.location.href == window.location.href) {
+ // not in frames, so add Frames button
+ addMenuItem("<a href='#' onclick='reframe();return true;'>Frames</a>");
+ bodyCls = "no-frame";
+ }
+ else {
+ bodyCls = "in-frame";
+ }
+ addClass(document.body, bodyCls);
+}
+
+function reframe() {
+ setCookie("haddock-reframe", document.URL);
+ window.location = "frames.html";
+}
+
+function postReframe() {
+ var s = getCookie("haddock-reframe");
+ if (s) {
+ parent.window.main.location = s;
+ clearCookie("haddock-reframe");
+ }
+}
+
+function styles() {
+ var i, a, es = document.getElementsByTagName("link"), rs = [];
+ for (i = 0; a = es[i]; i++) {
+ if(a.rel.indexOf("style") != -1 && a.title) {
+ rs.push(a);
+ }
+ }
+ return rs;
+}
+
+function addStyleMenu() {
+ var as = styles();
+ var i, a, btns = "";
+ for(i=0; a = as[i]; i++) {
+ btns += "<li><a href='#' onclick=\"setActiveStyleSheet('"
+ + a.title + "'); return false;\">"
+ + a.title + "</a></li>"
+ }
+ if (as.length > 1) {
+ var h = "<div id='style-menu-holder'>"
+ + "<a href='#' onclick='styleMenu(); return false;'>Style &#9662;</a>"
+ + "<ul id='style-menu' class='hide'>" + btns + "</ul>"
+ + "</div>";
+ addMenuItem(h);
+ }
+}
+
+function setActiveStyleSheet(title) {
+ var as = styles();
+ var i, a, found;
+ for(i=0; a = as[i]; i++) {
+ a.disabled = true;
+ // need to do this always, some browsers are edge triggered
+ if(a.title == title) {
+ found = a;
+ }
+ }
+ if (found) {
+ found.disabled = false;
+ setCookie("haddock-style", title);
+ }
+ else {
+ as[0].disabled = false;
+ clearCookie("haddock-style");
+ }
+ styleMenu(false);
+}
+
+function resetStyle() {
+ var s = getCookie("haddock-style");
+ if (s) setActiveStyleSheet(s);
+}
+
+
+function styleMenu(show) {
+ var m = document.getElementById('style-menu');
+ if (m) toggleShow(m, show);
+}
+
+
+function pageLoad() {
+ addStyleMenu();
+ adjustForFrames();
+ resetStyle();
+ restoreCollapsed();
+}
+
diff --git a/html-test/ref/hslogo-16.png b/html-test/ref/hslogo-16.png
new file mode 100644
index 00000000..0ff8579f
--- /dev/null
+++ b/html-test/ref/hslogo-16.png
Binary files differ
diff --git a/html-test/ref/mini_A.html b/html-test/ref/mini_A.html
new file mode 100644
index 00000000..cbe50e41
--- /dev/null
+++ b/html-test/ref/mini_A.html
@@ -0,0 +1,59 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >A</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >A</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >A</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >other</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >test2</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >X</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >reExport</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_AdvanceTypes.html b/html-test/ref/mini_AdvanceTypes.html
new file mode 100644
index 00000000..59d8dcb1
--- /dev/null
+++ b/html-test/ref/mini_AdvanceTypes.html
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >AdvanceTypes</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >AdvanceTypes</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >Pattern</a
+ > </p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_B.html b/html-test/ref/mini_B.html
new file mode 100644
index 00000000..211a7deb
--- /dev/null
+++ b/html-test/ref/mini_B.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >B</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >B</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >test</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >reExport</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >X</a
+ > </p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Bug1.html b/html-test/ref/mini_Bug1.html
new file mode 100644
index 00000000..adf81c73
--- /dev/null
+++ b/html-test/ref/mini_Bug1.html
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bug1</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Bug1</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >T</a
+ > </p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Bug2.html b/html-test/ref/mini_Bug2.html
new file mode 100644
index 00000000..b673e459
--- /dev/null
+++ b/html-test/ref/mini_Bug2.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bug2</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Bug2</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >x</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Bug3.html b/html-test/ref/mini_Bug3.html
new file mode 100644
index 00000000..af4cc445
--- /dev/null
+++ b/html-test/ref/mini_Bug3.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bug3</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Bug3</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >foo</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Bug4.html b/html-test/ref/mini_Bug4.html
new file mode 100644
index 00000000..b403e94a
--- /dev/null
+++ b/html-test/ref/mini_Bug4.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bug4</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Bug4</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >foo</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Bug6.html b/html-test/ref/mini_Bug6.html
new file mode 100644
index 00000000..5c5c1119
--- /dev/null
+++ b/html-test/ref/mini_Bug6.html
@@ -0,0 +1,65 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bug6</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Bug6</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >A</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >B</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >C</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >D</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >E</a
+ > </p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Bug7.html b/html-test/ref/mini_Bug7.html
new file mode 100644
index 00000000..1bec82ee
--- /dev/null
+++ b/html-test/ref/mini_Bug7.html
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bug7</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Bug7</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >Foo</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a href="" target="main"
+ >Bar</a
+ > x y</p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Bug8.html b/html-test/ref/mini_Bug8.html
new file mode 100644
index 00000000..070dbcf8
--- /dev/null
+++ b/html-test/ref/mini_Bug8.html
@@ -0,0 +1,63 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bug8</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Bug8</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >Typ</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >(--&gt;)</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >(---&gt;)</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >s</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >t</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >main</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_BugDeprecated.html b/html-test/ref/mini_BugDeprecated.html
new file mode 100644
index 00000000..f0410137
--- /dev/null
+++ b/html-test/ref/mini_BugDeprecated.html
@@ -0,0 +1,61 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >BugDeprecated</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >BugDeprecated</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >foo</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >baz</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >bar</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >one</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >three</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >two</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_BugExportHeadings.html b/html-test/ref/mini_BugExportHeadings.html
new file mode 100644
index 00000000..b481720d
--- /dev/null
+++ b/html-test/ref/mini_BugExportHeadings.html
@@ -0,0 +1,79 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >BugExportHeadings</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >BugExportHeadings</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >Foo
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >foo</a
+ ></p
+ ></div
+ ><h1
+ >Bar
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >bar</a
+ ></p
+ ></div
+ ><h1
+ >Baz
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >baz</a
+ ></p
+ ></div
+ ><h1
+ >One
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >one</a
+ ></p
+ ></div
+ ><h1
+ >Two
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >two</a
+ ></p
+ ></div
+ ><h1
+ >Three
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >three</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Bugs.html b/html-test/ref/mini_Bugs.html
new file mode 100644
index 00000000..3c758375
--- /dev/null
+++ b/html-test/ref/mini_Bugs.html
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Bugs</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Bugs</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >A</a
+ > a</p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_CrossPackageDocs.html b/html-test/ref/mini_CrossPackageDocs.html
new file mode 100644
index 00000000..4c0588ba
--- /dev/null
+++ b/html-test/ref/mini_CrossPackageDocs.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >CrossPackageDocs</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >CrossPackageDocs</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >map</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a href="" target="main"
+ >IsString</a
+ > a</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >runInteractiveProcess</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_DeprecatedClass.html b/html-test/ref/mini_DeprecatedClass.html
new file mode 100644
index 00000000..3923c1ff
--- /dev/null
+++ b/html-test/ref/mini_DeprecatedClass.html
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedClass</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >DeprecatedClass</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a href="" target="main"
+ >SomeClass</a
+ > a</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a href="" target="main"
+ >SomeOtherClass</a
+ > a</p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_DeprecatedData.html b/html-test/ref/mini_DeprecatedData.html
new file mode 100644
index 00000000..8ef20113
--- /dev/null
+++ b/html-test/ref/mini_DeprecatedData.html
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedData</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >DeprecatedData</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >Foo</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >One</a
+ > </p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_DeprecatedFunction.html b/html-test/ref/mini_DeprecatedFunction.html
new file mode 100644
index 00000000..9bb90dac
--- /dev/null
+++ b/html-test/ref/mini_DeprecatedFunction.html
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedFunction</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >DeprecatedFunction</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >foo</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >bar</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_DeprecatedFunction2.html b/html-test/ref/mini_DeprecatedFunction2.html
new file mode 100644
index 00000000..a03991a9
--- /dev/null
+++ b/html-test/ref/mini_DeprecatedFunction2.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedFunction2</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >DeprecatedFunction2</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >foo</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_DeprecatedFunction3.html b/html-test/ref/mini_DeprecatedFunction3.html
new file mode 100644
index 00000000..4ea60339
--- /dev/null
+++ b/html-test/ref/mini_DeprecatedFunction3.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedFunction3</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >DeprecatedFunction3</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >foo</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_DeprecatedModule.html b/html-test/ref/mini_DeprecatedModule.html
new file mode 100644
index 00000000..bfdef611
--- /dev/null
+++ b/html-test/ref/mini_DeprecatedModule.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedModule</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >DeprecatedModule</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >foo</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_DeprecatedModule2.html b/html-test/ref/mini_DeprecatedModule2.html
new file mode 100644
index 00000000..dbcc43b9
--- /dev/null
+++ b/html-test/ref/mini_DeprecatedModule2.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedModule2</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >DeprecatedModule2</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >foo</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_DeprecatedNewtype.html b/html-test/ref/mini_DeprecatedNewtype.html
new file mode 100644
index 00000000..a913525f
--- /dev/null
+++ b/html-test/ref/mini_DeprecatedNewtype.html
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedNewtype</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >DeprecatedNewtype</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >SomeNewType</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >SomeOtherNewType</a
+ > </p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_DeprecatedReExport.html b/html-test/ref/mini_DeprecatedReExport.html
new file mode 100644
index 00000000..8316dda5
--- /dev/null
+++ b/html-test/ref/mini_DeprecatedReExport.html
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedReExport</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >DeprecatedReExport</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >Re-exported from an other module
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >foo</a
+ ></p
+ ></div
+ ><h1
+ >Re-exported from an other package
+</h1
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_DeprecatedRecord.html b/html-test/ref/mini_DeprecatedRecord.html
new file mode 100644
index 00000000..3d949d2d
--- /dev/null
+++ b/html-test/ref/mini_DeprecatedRecord.html
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedRecord</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >DeprecatedRecord</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >Foo</a
+ > </p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_DeprecatedTypeFamily.html b/html-test/ref/mini_DeprecatedTypeFamily.html
new file mode 100644
index 00000000..c87d9637
--- /dev/null
+++ b/html-test/ref/mini_DeprecatedTypeFamily.html
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedTypeFamily</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >DeprecatedTypeFamily</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data family</span
+ > <a href=""
+ >SomeTypeFamily</a
+ > k :: * -&gt; *</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data family</span
+ > <a href=""
+ >SomeOtherTypeFamily</a
+ > k :: * -&gt; *</p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_DeprecatedTypeSynonym.html b/html-test/ref/mini_DeprecatedTypeSynonym.html
new file mode 100644
index 00000000..5ade100d
--- /dev/null
+++ b/html-test/ref/mini_DeprecatedTypeSynonym.html
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecatedTypeSynonym</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >DeprecatedTypeSynonym</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >type</span
+ > <a href="" target="main"
+ >TypeSyn</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >type</span
+ > <a href="" target="main"
+ >OtherTypeSyn</a
+ > </p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_DeprecationMessageParseError.html b/html-test/ref/mini_DeprecationMessageParseError.html
new file mode 100644
index 00000000..e52f487f
--- /dev/null
+++ b/html-test/ref/mini_DeprecationMessageParseError.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >DeprecationMessageParseError</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >DeprecationMessageParseError</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >foo</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Examples.html b/html-test/ref/mini_Examples.html
new file mode 100644
index 00000000..c99c2c48
--- /dev/null
+++ b/html-test/ref/mini_Examples.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Examples</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Examples</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >fib</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_FunArgs.html b/html-test/ref/mini_FunArgs.html
new file mode 100644
index 00000000..89729720
--- /dev/null
+++ b/html-test/ref/mini_FunArgs.html
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >FunArgs</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >FunArgs</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >f</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >g</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_GADTRecords.html b/html-test/ref/mini_GADTRecords.html
new file mode 100644
index 00000000..a8b838f0
--- /dev/null
+++ b/html-test/ref/mini_GADTRecords.html
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >GADTRecords</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >GADTRecords</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >H1</a
+ > a b</p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Hash.html b/html-test/ref/mini_Hash.html
new file mode 100644
index 00000000..1e6ad1a9
--- /dev/null
+++ b/html-test/ref/mini_Hash.html
@@ -0,0 +1,74 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Hash</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Hash</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >The <code
+ >HashTable</code
+ > type
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >HashTable</a
+ > key val</p
+ ></div
+ ><h2
+ >Operations on <code
+ >HashTable</code
+ >s
+</h2
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >new</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >insert</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >lookup</a
+ ></p
+ ></div
+ ><h1
+ >The <code
+ >Hash</code
+ > class
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a href="" target="main"
+ >Hash</a
+ > a</p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_HiddenInstances.html b/html-test/ref/mini_HiddenInstances.html
new file mode 100644
index 00000000..0f1a2e04
--- /dev/null
+++ b/html-test/ref/mini_HiddenInstances.html
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >HiddenInstances</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >HiddenInstances</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a href="" target="main"
+ >VisibleClass</a
+ > a</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >VisibleData</a
+ > </p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_HiddenInstancesB.html b/html-test/ref/mini_HiddenInstancesB.html
new file mode 100644
index 00000000..3ce4f6a9
--- /dev/null
+++ b/html-test/ref/mini_HiddenInstancesB.html
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >HiddenInstancesB</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >HiddenInstancesB</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a href="" target="main"
+ >Foo</a
+ > a</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >Bar</a
+ > </p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Hyperlinks.html b/html-test/ref/mini_Hyperlinks.html
new file mode 100644
index 00000000..f0c7d65a
--- /dev/null
+++ b/html-test/ref/mini_Hyperlinks.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Hyperlinks</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Hyperlinks</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >foo</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_IgnoreExports.html b/html-test/ref/mini_IgnoreExports.html
new file mode 100644
index 00000000..a420e65a
--- /dev/null
+++ b/html-test/ref/mini_IgnoreExports.html
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >IgnoreExports</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >IgnoreExports</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >foo</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >bar</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_ModuleWithWarning.html b/html-test/ref/mini_ModuleWithWarning.html
new file mode 100644
index 00000000..19315a14
--- /dev/null
+++ b/html-test/ref/mini_ModuleWithWarning.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >ModuleWithWarning</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >ModuleWithWarning</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >foo</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_NamedDoc.html b/html-test/ref/mini_NamedDoc.html
new file mode 100644
index 00000000..066bbc61
--- /dev/null
+++ b/html-test/ref/mini_NamedDoc.html
@@ -0,0 +1,25 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >NamedDoc</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >NamedDoc</p
+ ></div
+ ><div id="interface"
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_NoLayout.html b/html-test/ref/mini_NoLayout.html
new file mode 100644
index 00000000..19562d70
--- /dev/null
+++ b/html-test/ref/mini_NoLayout.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >NoLayout</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >NoLayout</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >g</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_NonGreedy.html b/html-test/ref/mini_NonGreedy.html
new file mode 100644
index 00000000..698c368e
--- /dev/null
+++ b/html-test/ref/mini_NonGreedy.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >NonGreedy</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >NonGreedy</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >f</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Properties.html b/html-test/ref/mini_Properties.html
new file mode 100644
index 00000000..5f538dfd
--- /dev/null
+++ b/html-test/ref/mini_Properties.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Properties</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Properties</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >fib</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_PruneWithWarning.html b/html-test/ref/mini_PruneWithWarning.html
new file mode 100644
index 00000000..9eb3aa00
--- /dev/null
+++ b/html-test/ref/mini_PruneWithWarning.html
@@ -0,0 +1,25 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >PruneWithWarning</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >PruneWithWarning</p
+ ></div
+ ><div id="interface"
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_QuasiExpr.html b/html-test/ref/mini_QuasiExpr.html
new file mode 100644
index 00000000..7dd9b829
--- /dev/null
+++ b/html-test/ref/mini_QuasiExpr.html
@@ -0,0 +1,59 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >QuasiExpr</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >QuasiExpr</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >Expr</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >BinOp</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >eval</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >expr</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >parseExprExp</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_QuasiQuote.html b/html-test/ref/mini_QuasiQuote.html
new file mode 100644
index 00000000..5dac6acc
--- /dev/null
+++ b/html-test/ref/mini_QuasiQuote.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >QuasiQuote</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >QuasiQuote</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >val</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_SpuriousSuperclassConstraints.html b/html-test/ref/mini_SpuriousSuperclassConstraints.html
new file mode 100644
index 00000000..22079a4e
--- /dev/null
+++ b/html-test/ref/mini_SpuriousSuperclassConstraints.html
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >SpuriousSuperclassConstraints</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >SpuriousSuperclassConstraints</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >SomeType</a
+ > f a</p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_TH.html b/html-test/ref/mini_TH.html
new file mode 100644
index 00000000..d2ddbabc
--- /dev/null
+++ b/html-test/ref/mini_TH.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >TH</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >TH</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >decl</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_TH2.html b/html-test/ref/mini_TH2.html
new file mode 100644
index 00000000..2c9f1340
--- /dev/null
+++ b/html-test/ref/mini_TH2.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >TH2</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >TH2</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >f</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Test.html b/html-test/ref/mini_Test.html
new file mode 100644
index 00000000..26db2c0f
--- /dev/null
+++ b/html-test/ref/mini_Test.html
@@ -0,0 +1,269 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Test</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Test</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >Type declarations
+</h1
+ ><h2
+ >Data types
+</h2
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >T</a
+ > a b</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >T2</a
+ > a b</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >T3</a
+ > a b</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >T4</a
+ > a b</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >T5</a
+ > a b</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >T6</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >N1</a
+ > a</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >N2</a
+ > a b</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >N3</a
+ > a b</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >N4</a
+ > a b</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >N5</a
+ > a b</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >N6</a
+ > a b</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >N7</a
+ > a b</p
+ ></div
+ ><h2
+ >Records
+</h2
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >R</a
+ > </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >R1</a
+ > </p
+ ></div
+ ><h1
+ >Class declarations
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a href="" target="main"
+ >C</a
+ > a</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a href="" target="main"
+ >D</a
+ > a</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a href="" target="main"
+ >E</a
+ > a</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a href="" target="main"
+ >F</a
+ > a</p
+ ></div
+ ><h1
+ >Function types
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >f</a
+ ></p
+ ></div
+ ><h1
+ >Auxiliary stuff
+</h1
+ ><h1
+ >A hidden module
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >hidden</a
+ ></p
+ ></div
+ ><h1
+ >A visible module
+</h1
+ ><h1
+ >Existential / Universal types
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >Ex</a
+ > a</p
+ ></div
+ ><h1
+ >Type signatures with argument docs
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >k</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >l</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >m</a
+ ></p
+ ></div
+ ><h1
+ >A section
+</h1
+ ><h2
+ >A subsection
+</h2
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >f'</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >withType</a
+ ></p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >withoutType</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Ticket112.html b/html-test/ref/mini_Ticket112.html
new file mode 100644
index 00000000..68a0a5e5
--- /dev/null
+++ b/html-test/ref/mini_Ticket112.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Ticket112</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Ticket112</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >f</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Ticket61.html b/html-test/ref/mini_Ticket61.html
new file mode 100644
index 00000000..a73fefca
--- /dev/null
+++ b/html-test/ref/mini_Ticket61.html
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Ticket61</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Ticket61</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a href="" target="main"
+ >C</a
+ > a</p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Ticket75.html b/html-test/ref/mini_Ticket75.html
new file mode 100644
index 00000000..75ce882c
--- /dev/null
+++ b/html-test/ref/mini_Ticket75.html
@@ -0,0 +1,39 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Ticket75</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Ticket75</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > a <a href="" target="main"
+ >:-</a
+ > b</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >f</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_TypeFamilies.html b/html-test/ref/mini_TypeFamilies.html
new file mode 100644
index 00000000..0cf39c88
--- /dev/null
+++ b/html-test/ref/mini_TypeFamilies.html
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >TypeFamilies</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >TypeFamilies</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >type family</span
+ > <a href=""
+ >G</a
+ > a :: *</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >class</span
+ > <a href="" target="main"
+ >A</a
+ > a</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >type family</span
+ > <a href=""
+ >F</a
+ > a </p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >g</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_TypeOperators.html b/html-test/ref/mini_TypeOperators.html
new file mode 100644
index 00000000..86b6beec
--- /dev/null
+++ b/html-test/ref/mini_TypeOperators.html
@@ -0,0 +1,66 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >TypeOperators</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >TypeOperators</p
+ ></div
+ ><div id="interface"
+ ><h1
+ >stuff
+</h1
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > a <a href="" target="main"
+ >:-:</a
+ > b</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > (a <a href="" target="main"
+ >:+:</a
+ > b) c</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >Op</a
+ > a b</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><span class="keyword"
+ >data</span
+ > <a href="" target="main"
+ >O</a
+ > g f a</p
+ ></div
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >biO</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Unicode.html b/html-test/ref/mini_Unicode.html
new file mode 100644
index 00000000..55336980
--- /dev/null
+++ b/html-test/ref/mini_Unicode.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Unicode</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Unicode</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >x</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/mini_Visible.html b/html-test/ref/mini_Visible.html
new file mode 100644
index 00000000..976a30c5
--- /dev/null
+++ b/html-test/ref/mini_Visible.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+><head
+ ><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"
+ /><title
+ >Visible</title
+ ><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean"
+ /><script src="haddock-util.js" type="text/javascript"
+ ></script
+ ><script type="text/javascript"
+ >//<![CDATA[
+window.onload = function () {pageLoad();};
+//]]>
+</script
+ ></head
+ ><body id="mini"
+ ><div id="module-header"
+ ><p class="caption"
+ >Visible</p
+ ></div
+ ><div id="interface"
+ ><div class="top"
+ ><p class="src"
+ ><a href="" target="main"
+ >visible</a
+ ></p
+ ></div
+ ></div
+ ></body
+ ></html
+>
diff --git a/html-test/ref/minus.gif b/html-test/ref/minus.gif
new file mode 100644
index 00000000..1deac2fe
--- /dev/null
+++ b/html-test/ref/minus.gif
Binary files differ
diff --git a/html-test/ref/ocean.css b/html-test/ref/ocean.css
new file mode 100644
index 00000000..42238709
--- /dev/null
+++ b/html-test/ref/ocean.css
@@ -0,0 +1,546 @@
+/* @group Fundamentals */
+
+* { margin: 0; padding: 0 }
+
+/* Is this portable? */
+html {
+ background-color: white;
+ width: 100%;
+ height: 100%;
+}
+
+body {
+ background: white;
+ color: black;
+ text-align: left;
+ min-height: 100%;
+ position: relative;
+}
+
+p {
+ margin: 0.8em 0;
+}
+
+ul, ol {
+ margin: 0.8em 0 0.8em 2em;
+}
+
+dl {
+ margin: 0.8em 0;
+}
+
+dt {
+ font-weight: bold;
+}
+dd {
+ margin-left: 2em;
+}
+
+a { text-decoration: none; }
+a[href]:link { color: rgb(196,69,29); }
+a[href]:visited { color: rgb(171,105,84); }
+a[href]:hover { text-decoration:underline; }
+
+/* @end */
+
+/* @group Fonts & Sizes */
+
+/* Basic technique & IE workarounds from YUI 3
+ For reasons, see:
+ http://yui.yahooapis.com/3.1.1/build/cssfonts/fonts.css
+ */
+
+body {
+ font:13px/1.4 sans-serif;
+ *font-size:small; /* for IE */
+ *font:x-small; /* for IE in quirks mode */
+}
+
+h1 { font-size: 146.5%; /* 19pt */ }
+h2 { font-size: 131%; /* 17pt */ }
+h3 { font-size: 116%; /* 15pt */ }
+h4 { font-size: 100%; /* 13pt */ }
+h5 { font-size: 100%; /* 13pt */ }
+
+select, input, button, textarea {
+ font:99% sans-serif;
+}
+
+table {
+ font-size:inherit;
+ font:100%;
+}
+
+pre, code, kbd, samp, tt, .src {
+ font-family:monospace;
+ *font-size:108%;
+ line-height: 124%;
+}
+
+.links, .link {
+ font-size: 85%; /* 11pt */
+}
+
+#module-header .caption {
+ font-size: 182%; /* 24pt */
+}
+
+.info {
+ font-size: 85%; /* 11pt */
+}
+
+#table-of-contents, #synopsis {
+ /* font-size: 85%; /* 11pt */
+}
+
+
+/* @end */
+
+/* @group Common */
+
+.caption, h1, h2, h3, h4, h5, h6 {
+ font-weight: bold;
+ color: rgb(78,98,114);
+ margin: 0.8em 0 0.4em;
+}
+
+* + h1, * + h2, * + h3, * + h4, * + h5, * + h6 {
+ margin-top: 2em;
+}
+
+h1 + h2, h2 + h3, h3 + h4, h4 + h5, h5 + h6 {
+ margin-top: inherit;
+}
+
+ul.links {
+ list-style: none;
+ text-align: left;
+ float: right;
+ display: inline-table;
+ margin: 0 0 0 1em;
+}
+
+ul.links li {
+ display: inline;
+ border-left: 1px solid #d5d5d5;
+ white-space: nowrap;
+ padding: 0;
+}
+
+ul.links li a {
+ padding: 0.2em 0.5em;
+}
+
+.hide { display: none; }
+.show { display: inherit; }
+.clear { clear: both; }
+
+.collapser {
+ background-image: url(minus.gif);
+ background-repeat: no-repeat;
+}
+.expander {
+ background-image: url(plus.gif);
+ background-repeat: no-repeat;
+}
+p.caption.collapser,
+p.caption.expander {
+ background-position: 0 0.4em;
+}
+.collapser, .expander {
+ padding-left: 14px;
+ margin-left: -14px;
+ cursor: pointer;
+}
+
+pre {
+ padding: 0.25em;
+ margin: 0.8em 0;
+ background: rgb(229,237,244);
+ overflow: auto;
+ border-bottom: 0.25em solid white;
+ /* white border adds some space below the box to compensate
+ for visual extra space that paragraphs have between baseline
+ and the bounding box */
+}
+
+.src {
+ background: #f0f0f0;
+ padding: 0.2em 0.5em;
+}
+
+.keyword { font-weight: normal; }
+.def { font-weight: bold; }
+
+
+/* @end */
+
+/* @group Page Structure */
+
+#content {
+ margin: 0 auto;
+ padding: 0 2em 6em;
+}
+
+#package-header {
+ background: rgb(41,56,69);
+ border-top: 5px solid rgb(78,98,114);
+ color: #ddd;
+ padding: 0.2em;
+ position: relative;
+ text-align: left;
+}
+
+#package-header .caption {
+ background: url(hslogo-16.png) no-repeat 0em;
+ color: white;
+ margin: 0 2em;
+ font-weight: normal;
+ font-style: normal;
+ padding-left: 2em;
+}
+
+#package-header a:link, #package-header a:visited { color: white; }
+#package-header a:hover { background: rgb(78,98,114); }
+
+#module-header .caption {
+ color: rgb(78,98,114);
+ font-weight: bold;
+ border-bottom: 1px solid #ddd;
+}
+
+table.info {
+ float: right;
+ padding: 0.5em 1em;
+ border: 1px solid #ddd;
+ color: rgb(78,98,114);
+ background-color: #fff;
+ max-width: 40%;
+ border-spacing: 0;
+ position: relative;
+ top: -0.5em;
+ margin: 0 0 0 2em;
+}
+
+.info th {
+ padding: 0 1em 0 0;
+}
+
+div#style-menu-holder {
+ position: relative;
+ z-index: 2;
+ display: inline;
+}
+
+#style-menu {
+ position: absolute;
+ z-index: 1;
+ overflow: visible;
+ background: #374c5e;
+ margin: 0;
+ text-align: center;
+ right: 0;
+ padding: 0;
+ top: 1.25em;
+}
+
+#style-menu li {
+ display: list-item;
+ border-style: none;
+ margin: 0;
+ padding: 0;
+ color: #000;
+ list-style-type: none;
+}
+
+#style-menu li + li {
+ border-top: 1px solid #919191;
+}
+
+#style-menu a {
+ width: 6em;
+ padding: 3px;
+ display: block;
+}
+
+#footer {
+ background: #ddd;
+ border-top: 1px solid #aaa;
+ padding: 0.5em 0;
+ color: #666;
+ text-align: center;
+ position: absolute;
+ bottom: 0;
+ width: 100%;
+ height: 3em;
+}
+
+/* @end */
+
+/* @group Front Matter */
+
+#table-of-contents {
+ float: right;
+ clear: right;
+ background: #faf9dc;
+ border: 1px solid #d8d7ad;
+ padding: 0.5em 1em;
+ max-width: 20em;
+ margin: 0.5em 0 1em 1em;
+}
+
+#table-of-contents .caption {
+ text-align: center;
+ margin: 0;
+}
+
+#table-of-contents ul {
+ list-style: none;
+ margin: 0;
+}
+
+#table-of-contents ul ul {
+ margin-left: 2em;
+}
+
+#description .caption {
+ display: none;
+}
+
+#synopsis {
+ display: none;
+}
+
+.no-frame #synopsis {
+ display: block;
+ position: fixed;
+ right: 0;
+ height: 80%;
+ top: 10%;
+ padding: 0;
+}
+
+#synopsis .caption {
+ float: left;
+ width: 29px;
+ color: rgba(255,255,255,0);
+ height: 110px;
+ margin: 0;
+ font-size: 1px;
+ padding: 0;
+}
+
+#synopsis p.caption.collapser {
+ background: url(synopsis.png) no-repeat -64px -8px;
+}
+
+#synopsis p.caption.expander {
+ background: url(synopsis.png) no-repeat 0px -8px;
+}
+
+#synopsis ul {
+ height: 100%;
+ overflow: auto;
+ padding: 0.5em;
+ margin: 0;
+}
+
+#synopsis ul ul {
+ overflow: hidden;
+}
+
+#synopsis ul,
+#synopsis ul li.src {
+ background-color: #faf9dc;
+ white-space: nowrap;
+ list-style: none;
+ margin-left: 0;
+}
+
+/* @end */
+
+/* @group Main Content */
+
+#interface div.top { margin: 2em 0; }
+#interface h1 + div.top,
+#interface h2 + div.top,
+#interface h3 + div.top,
+#interface h4 + div.top,
+#interface h5 + div.top {
+ margin-top: 1em;
+}
+#interface p.src .link {
+ float: right;
+ color: #919191;
+ border-left: 1px solid #919191;
+ background: #f0f0f0;
+ padding: 0 0.5em 0.2em;
+ margin: 0 -0.5em 0 0.5em;
+}
+
+#interface table { border-spacing: 2px; }
+#interface td {
+ vertical-align: top;
+ padding-left: 0.5em;
+}
+#interface td.src {
+ white-space: nowrap;
+}
+#interface td.doc p {
+ margin: 0;
+}
+#interface td.doc p + p {
+ margin-top: 0.8em;
+}
+
+.subs dl {
+ margin: 0;
+}
+
+.subs dt {
+ float: left;
+ clear: left;
+ display: block;
+ margin: 1px 0;
+}
+
+.subs dd {
+ float: right;
+ width: 90%;
+ display: block;
+ padding-left: 0.5em;
+ margin-bottom: 0.5em;
+}
+
+.subs dd.empty {
+ display: none;
+}
+
+.subs dd p {
+ margin: 0;
+}
+
+.top p.src {
+ border-top: 1px solid #ccc;
+}
+
+.subs, .doc {
+ /* use this selector for one level of indent */
+ padding-left: 2em;
+}
+
+.warning {
+ color: red;
+}
+
+.arguments {
+ margin-top: -0.4em;
+}
+.arguments .caption {
+ display: none;
+}
+
+.fields { padding-left: 1em; }
+
+.fields .caption { display: none; }
+
+.fields p { margin: 0 0; }
+
+/* this seems bulky to me
+.methods, .constructors {
+ background: #f8f8f8;
+ border: 1px solid #eee;
+}
+*/
+
+/* @end */
+
+/* @group Auxillary Pages */
+
+#mini {
+ margin: 0 auto;
+ padding: 0 1em 1em;
+}
+
+#mini > * {
+ font-size: 93%; /* 12pt */
+}
+
+#mini #module-list .caption,
+#mini #module-header .caption {
+ font-size: 125%; /* 15pt */
+}
+
+#mini #interface h1,
+#mini #interface h2,
+#mini #interface h3,
+#mini #interface h4 {
+ font-size: 109%; /* 13pt */
+ margin: 1em 0 0;
+}
+
+#mini #interface .top,
+#mini #interface .src {
+ margin: 0;
+}
+
+#mini #module-list ul {
+ list-style: none;
+ margin: 0;
+}
+
+#alphabet ul {
+ list-style: none;
+ padding: 0;
+ margin: 0.5em 0 0;
+ text-align: center;
+}
+
+#alphabet li {
+ display: inline;
+ margin: 0 0.25em;
+}
+
+#alphabet a {
+ font-weight: bold;
+}
+
+#index .caption,
+#module-list .caption { font-size: 131%; /* 17pt */ }
+
+#index table {
+ margin-left: 2em;
+}
+
+#index .src {
+ font-weight: bold;
+}
+#index .alt {
+ font-size: 77%; /* 10pt */
+ font-style: italic;
+ padding-left: 2em;
+}
+
+#index td + td {
+ padding-left: 1em;
+}
+
+#module-list ul {
+ list-style: none;
+ margin: 0 0 0 2em;
+}
+
+#module-list li {
+ clear: right;
+}
+
+#module-list span.collapser,
+#module-list span.expander {
+ background-position: 0 0.3em;
+}
+
+#module-list .package {
+ float: right;
+}
+
+/* @end */
diff --git a/html-test/ref/plus.gif b/html-test/ref/plus.gif
new file mode 100644
index 00000000..2d15c141
--- /dev/null
+++ b/html-test/ref/plus.gif
Binary files differ
diff --git a/html-test/ref/synopsis.png b/html-test/ref/synopsis.png
new file mode 100644
index 00000000..85fb86ec
--- /dev/null
+++ b/html-test/ref/synopsis.png
Binary files differ
diff --git a/html-test/run.lhs b/html-test/run.lhs
new file mode 100755
index 00000000..7d3b805b
--- /dev/null
+++ b/html-test/run.lhs
@@ -0,0 +1,156 @@
+#!/usr/bin/env runhaskell
+\begin{code}
+{-# LANGUAGE CPP #-}
+import Prelude hiding (mod)
+import Control.Monad
+import Control.Applicative
+import Data.List
+import Data.Maybe
+import Distribution.InstalledPackageInfo
+import Distribution.Package (PackageName (..))
+import Distribution.Simple.Compiler
+import Distribution.Simple.GHC
+import Distribution.Simple.PackageIndex
+import Distribution.Simple.Program
+import Distribution.Simple.Utils
+import Distribution.Verbosity
+import System.IO
+import System.Cmd
+import System.Directory
+import System.Environment
+import System.Exit
+import System.FilePath
+import System.Process (ProcessHandle, runProcess, waitForProcess)
+
+
+packageRoot, dataDir, haddockPath, baseDir, testDir, outDir :: FilePath
+baseDir = takeDirectory __FILE__
+testDir = baseDir </> "src"
+refDir = baseDir </> "ref"
+outDir = baseDir </> "out"
+packageRoot = baseDir </> ".."
+dataDir = packageRoot </> "resources"
+haddockPath = packageRoot </> "dist" </> "build" </> "haddock" </> "haddock"
+
+
+main :: IO ()
+main = do
+ test
+ putStrLn "All tests passed!"
+
+
+test :: IO ()
+test = do
+ x <- doesFileExist haddockPath
+ unless x $ die "you need to run 'cabal build' successfully first"
+
+ contents <- getDirectoryContents testDir
+ args <- getArgs
+ let (opts, spec) = span ("-" `isPrefixOf`) args
+ let mods =
+ case spec of
+ y:_ | y /= "all" -> [y ++ ".hs"]
+ _ -> filter ((==) ".hs" . takeExtension) contents
+
+ let mods' = map (testDir </>) mods
+
+ -- add haddock_datadir to environment for subprocesses
+ env <- Just . (:) ("haddock_datadir", dataDir) <$> getEnvironment
+
+ putStrLn ""
+ putStrLn "Haddock version: "
+ h1 <- runProcess haddockPath ["--version"] Nothing
+ env Nothing Nothing Nothing
+ wait h1 "*** Running `haddock --version' failed!"
+ putStrLn ""
+ putStrLn "GHC version: "
+ h2 <- runProcess haddockPath ["--ghc-version"] Nothing
+ env Nothing Nothing Nothing
+ wait h2 "*** Running `haddock --ghc-version' failed!"
+ putStrLn ""
+
+ -- TODO: maybe do something more clever here using haddock.cabal
+ ghcPath <- fmap init $ rawSystemStdout normal haddockPath ["--print-ghc-path"]
+ (_, conf) <- configure normal (Just ghcPath) Nothing defaultProgramConfiguration
+ pkgIndex <- getInstalledPackages normal [GlobalPackageDB] conf
+ let mkDep pkgName =
+ fromMaybe (error "Couldn't find test dependencies") $ do
+ let pkgs = lookupPackageName pkgIndex (PackageName pkgName)
+ (_, pkgs') <- listToMaybe pkgs
+ pkg <- listToMaybe pkgs'
+ ifacePath <- listToMaybe (haddockInterfaces pkg)
+ htmlPath <- listToMaybe (haddockHTMLs pkg)
+ return ("-i " ++ htmlPath ++ "," ++ ifacePath)
+
+ let base = mkDep "base"
+ process = mkDep "process"
+ ghcprim = mkDep "ghc-prim"
+
+ putStrLn "Running tests..."
+ handle <- runProcess haddockPath
+ (["-w", "-o", outDir, "-h", "--pretty-html", "--optghc=-fglasgow-exts"
+ , "--optghc=-w", base, process, ghcprim] ++ opts ++ mods')
+ Nothing env Nothing
+ Nothing Nothing
+
+ wait handle "*** Haddock run failed! Exiting."
+ check mods (if not (null args) && args !! 0 == "all" then False else True)
+ where
+ wait :: ProcessHandle -> String -> IO ()
+ wait h msg = do
+ r <- waitForProcess h
+ unless (r == ExitSuccess) $ do
+ hPutStrLn stderr msg
+ exitFailure
+
+check :: [FilePath] -> Bool -> IO ()
+check modules strict = do
+ forM_ modules $ \mod -> do
+ let outfile = outDir </> dropExtension mod ++ ".html"
+ let reffile = refDir </> dropExtension mod ++ ".html"
+ b <- doesFileExist reffile
+ if b
+ then do
+ out <- readFile outfile
+ ref <- readFile reffile
+ if not $ haddockEq out ref
+ then do
+ putStrLn $ "Output for " ++ mod ++ " has changed! Exiting with diff:"
+ let ref' = stripLinks ref
+ out' = stripLinks out
+ let reffile' = outDir </> takeFileName reffile ++ ".nolinks"
+ outfile' = outDir </> takeFileName outfile ++ ".ref.nolinks"
+ writeFile reffile' ref'
+ writeFile outfile' out'
+ r <- programOnPath "colordiff"
+ code <- if r
+ then system $ "colordiff " ++ reffile' ++ " " ++ outfile'
+ else system $ "diff " ++ reffile' ++ " " ++ outfile'
+ if strict then exitFailure else return ()
+ unless (code == ExitSuccess) $ do
+ hPutStrLn stderr "*** Running diff failed!"
+ exitFailure
+ else do
+ putStrLn $ "Pass: " ++ mod
+ else do
+ putStrLn $ "Pass: " ++ mod ++ " (no .ref file)"
+
+
+haddockEq :: String -> String -> Bool
+haddockEq file1 file2 = stripLinks file1 == stripLinks file2
+
+stripLinks :: String -> String
+stripLinks str =
+ let prefix = "<a href=\"" in
+ case stripPrefix prefix str of
+ Just str' -> prefix ++ stripLinks (dropWhile (/= '"') str')
+ Nothing ->
+ case str of
+ [] -> []
+ x : xs -> x : stripLinks xs
+
+programOnPath :: FilePath -> IO Bool
+programOnPath p = do
+ result <- findProgramLocation silent p
+ return (isJust result)
+\end{code}
diff --git a/html-test/src/A.hs b/html-test/src/A.hs
new file mode 100644
index 00000000..606b0865
--- /dev/null
+++ b/html-test/src/A.hs
@@ -0,0 +1,17 @@
+module A where
+
+data A = A
+
+other :: Int
+other = 2
+
+-- | Doc for test2
+test2 :: Bool
+test2 = False
+
+-- | Should show up on the page for both modules A and B
+data X = X -- ^ Doc for consructor
+
+-- | Should show up on the page for both modules A and B
+reExport :: Int
+reExport = 1
diff --git a/html-test/src/AdvanceTypes.hs b/html-test/src/AdvanceTypes.hs
new file mode 100644
index 00000000..939fdf07
--- /dev/null
+++ b/html-test/src/AdvanceTypes.hs
@@ -0,0 +1,9 @@
+{-# LANGUAGE DataKinds #-}
+{-# LANGUAGE GADTs #-}
+{-# LANGUAGE KindSignatures #-}
+{-# LANGUAGE TypeOperators #-}
+module AdvanceTypes where
+
+data Pattern :: [*] -> * where
+ Nil :: Pattern '[]
+ Cons :: Maybe h -> Pattern t -> Pattern (h ': t)
diff --git a/html-test/src/B.hs b/html-test/src/B.hs
new file mode 100644
index 00000000..5fd69acd
--- /dev/null
+++ b/html-test/src/B.hs
@@ -0,0 +1,8 @@
+module B ( module A, test, reExport, X(..) ) where
+import A ( A(..), test2, reExport, X(..) )
+
+-- | This link shouldn't work: 'other'.
+-- These links should work: 'A.other', 'Data.List.sortBy', 'test2', 'A.test2', 'Data.Maybe.fromMaybe'.
+-- Module link: "Prelude".
+test :: Int
+test = 1
diff --git a/html-test/src/Bug1.hs b/html-test/src/Bug1.hs
new file mode 100644
index 00000000..af1ed4d3
--- /dev/null
+++ b/html-test/src/Bug1.hs
@@ -0,0 +1,6 @@
+module Bug1 where
+
+-- | We should have different anchors for constructors and types\/classes. This
+-- hyperlink should point to the type constructor by default: 'T'.
+data T = T
+
diff --git a/html-test/src/Bug2.hs b/html-test/src/Bug2.hs
new file mode 100644
index 00000000..9121922e
--- /dev/null
+++ b/html-test/src/Bug2.hs
@@ -0,0 +1,4 @@
+module Bug2 ( x ) where
+import B
+x :: A
+x = A
diff --git a/html-test/src/Bug3.hs b/html-test/src/Bug3.hs
new file mode 100644
index 00000000..67e57892
--- /dev/null
+++ b/html-test/src/Bug3.hs
@@ -0,0 +1,6 @@
+module Bug3 where
+
+-- | /multi-line
+-- emphasis/
+foo :: Int
+foo = undefined
diff --git a/html-test/src/Bug4.hs b/html-test/src/Bug4.hs
new file mode 100644
index 00000000..425a77aa
--- /dev/null
+++ b/html-test/src/Bug4.hs
@@ -0,0 +1,5 @@
+module Bug4 where
+-- | don't use apostrophe's in the wrong place's
+foo :: Int
+foo = undefined
+
diff --git a/html-test/src/Bug6.hs b/html-test/src/Bug6.hs
new file mode 100644
index 00000000..17411f31
--- /dev/null
+++ b/html-test/src/Bug6.hs
@@ -0,0 +1,23 @@
+-- | Exporting records.
+module Bug6( A(A), B(B), b, C(C,c1,c2), D(D,d1), E(E) ) where
+
+-- |
+-- This record is exported without its field
+data A = A { a :: Int }
+
+-- |
+-- .. with its field, but the field is named separately in the export list
+-- (the field isn't documented separately since it is already documented here)
+data B = B { b :: Int }
+
+-- |
+-- .. with fields names as subordinate names in the export
+data C = C { c1 :: Int, c2 :: Int }
+
+-- |
+-- .. with only some of the fields exported (we can't handle this one -
+-- how do we render the declaration?)
+data D = D { d1 :: Int, d2 :: Int }
+
+-- | a newtype with a field
+newtype E = E { e :: Int }
diff --git a/html-test/src/Bug7.hs b/html-test/src/Bug7.hs
new file mode 100644
index 00000000..8cf57914
--- /dev/null
+++ b/html-test/src/Bug7.hs
@@ -0,0 +1,12 @@
+-- | This module caused a duplicate instance in the documentation for the Foo
+-- type.
+module Bug7 where
+
+-- | The Foo datatype
+data Foo = Foo
+
+-- | The Bar class
+class Bar x y
+
+-- | Just one instance
+instance Bar Foo Foo
diff --git a/html-test/src/Bug8.hs b/html-test/src/Bug8.hs
new file mode 100644
index 00000000..18df63c8
--- /dev/null
+++ b/html-test/src/Bug8.hs
@@ -0,0 +1,14 @@
+module Bug8 where
+
+infix -->
+infix --->
+
+data Typ = Type (String,[Typ])
+ | TFree (String, [String])
+
+x --> y = Type("fun",[s,t])
+(--->) = flip $ foldr (-->)
+
+s = undefined
+t = undefined
+main = undefined
diff --git a/html-test/src/BugDeprecated.hs b/html-test/src/BugDeprecated.hs
new file mode 100644
index 00000000..0f7ac2eb
--- /dev/null
+++ b/html-test/src/BugDeprecated.hs
@@ -0,0 +1,18 @@
+module BugDeprecated where
+
+foo, bar, baz :: Int
+foo = 23
+bar = 23
+baz = 23
+{-# DEPRECATED foo "for foo" #-}
+{-# DEPRECATED bar "for bar" #-}
+{-# DEPRECATED baz "for baz" #-}
+
+-- | some documentation for one, two and three
+one, two, three :: Int
+one = 23
+two = 23
+three = 23
+{-# DEPRECATED one "for one" #-}
+{-# DEPRECATED two "for two" #-}
+{-# DEPRECATED three "for three" #-}
diff --git a/html-test/src/BugExportHeadings.hs b/html-test/src/BugExportHeadings.hs
new file mode 100644
index 00000000..a5493a08
--- /dev/null
+++ b/html-test/src/BugExportHeadings.hs
@@ -0,0 +1,29 @@
+-- test for #192
+module BugExportHeadings (
+-- * Foo
+ foo
+-- * Bar
+, bar
+-- * Baz
+, baz
+
+-- * One
+, one
+-- * Two
+, two
+-- * Three
+, three
+) where
+
+foo, bar, baz :: Int
+foo = 23
+bar = 23
+baz = 23
+
+one, two, three :: Int
+one = 23
+two = 23
+three = 23
+{-# DEPRECATED one "for one" #-}
+{-# DEPRECATED two "for two" #-}
+{-# DEPRECATED three "for three" #-}
diff --git a/html-test/src/Bugs.hs b/html-test/src/Bugs.hs
new file mode 100644
index 00000000..8e1f0079
--- /dev/null
+++ b/html-test/src/Bugs.hs
@@ -0,0 +1,3 @@
+module Bugs where
+
+data A a = A a (a -> Int)
diff --git a/html-test/src/CrossPackageDocs.hs b/html-test/src/CrossPackageDocs.hs
new file mode 100644
index 00000000..4d529f79
--- /dev/null
+++ b/html-test/src/CrossPackageDocs.hs
@@ -0,0 +1,4 @@
+module CrossPackageDocs (map, IsString(..), runInteractiveProcess) where
+
+import System.Process
+import Data.String
diff --git a/html-test/src/DeprecatedClass.hs b/html-test/src/DeprecatedClass.hs
new file mode 100644
index 00000000..018904ab
--- /dev/null
+++ b/html-test/src/DeprecatedClass.hs
@@ -0,0 +1,15 @@
+module DeprecatedClass where
+
+-- | some class
+class SomeClass a where
+ -- | documentation for foo
+ foo :: a -> a
+
+{-# DEPRECATED SomeClass "SomeClass" #-}
+{-# DEPRECATED foo "foo" #-}
+
+class SomeOtherClass a where
+ bar :: a -> a
+
+{-# DEPRECATED SomeOtherClass "SomeOtherClass" #-}
+{-# DEPRECATED bar "bar" #-}
diff --git a/html-test/src/DeprecatedData.hs b/html-test/src/DeprecatedData.hs
new file mode 100644
index 00000000..c40ba122
--- /dev/null
+++ b/html-test/src/DeprecatedData.hs
@@ -0,0 +1,15 @@
+{-# LANGUAGE TypeFamilies #-}
+module DeprecatedData where
+
+-- | type Foo
+data Foo = Foo -- ^ constructor Foo
+ | Bar -- ^ constructor Bar
+
+{-# DEPRECATED Foo "Foo" #-}
+{-# DEPRECATED Bar "Bar" #-}
+
+data One = One
+ | Two
+
+{-# DEPRECATED One "One" #-}
+{-# DEPRECATED Two "Two" #-}
diff --git a/html-test/src/DeprecatedFunction.hs b/html-test/src/DeprecatedFunction.hs
new file mode 100644
index 00000000..8d626435
--- /dev/null
+++ b/html-test/src/DeprecatedFunction.hs
@@ -0,0 +1,10 @@
+module DeprecatedFunction where
+
+-- | some documentation for foo
+foo :: Int
+foo = 23
+{-# DEPRECATED foo "use `bar` instead" #-}
+
+-- | some documentation for bar
+bar :: Int
+bar = 42
diff --git a/html-test/src/DeprecatedFunction2.hs b/html-test/src/DeprecatedFunction2.hs
new file mode 100644
index 00000000..bdbbf95c
--- /dev/null
+++ b/html-test/src/DeprecatedFunction2.hs
@@ -0,0 +1,6 @@
+module DeprecatedFunction2 where
+
+
+foo :: Int
+foo = 23
+{-# DEPRECATED foo "use bar instead" #-}
diff --git a/html-test/src/DeprecatedFunction3.hs b/html-test/src/DeprecatedFunction3.hs
new file mode 100644
index 00000000..ca719bda
--- /dev/null
+++ b/html-test/src/DeprecatedFunction3.hs
@@ -0,0 +1,6 @@
+module DeprecatedFunction3 where
+
+
+
+foo = 23
+{-# DEPRECATED foo "use bar instead" #-}
diff --git a/html-test/src/DeprecatedModule.hs b/html-test/src/DeprecatedModule.hs
new file mode 100644
index 00000000..369dba4f
--- /dev/null
+++ b/html-test/src/DeprecatedModule.hs
@@ -0,0 +1,5 @@
+-- | Documentation for "DeprecatedModule".
+module DeprecatedModule {-# DEPRECATED "Use \"Foo\" instead" #-} where
+
+foo :: Int
+foo = 23
diff --git a/html-test/src/DeprecatedModule2.hs b/html-test/src/DeprecatedModule2.hs
new file mode 100644
index 00000000..94185297
--- /dev/null
+++ b/html-test/src/DeprecatedModule2.hs
@@ -0,0 +1,4 @@
+module DeprecatedModule2 {-# DEPRECATED "Use Foo instead" #-} where
+
+foo :: Int
+foo = 23
diff --git a/html-test/src/DeprecatedNewtype.hs b/html-test/src/DeprecatedNewtype.hs
new file mode 100644
index 00000000..254f1f55
--- /dev/null
+++ b/html-test/src/DeprecatedNewtype.hs
@@ -0,0 +1,10 @@
+module DeprecatedNewtype where
+
+-- | some documentation
+newtype SomeNewType = SomeNewTypeConst String {- ^ constructor docu -}
+{-# DEPRECATED SomeNewType "SomeNewType" #-}
+{-# DEPRECATED SomeNewTypeConst "SomeNewTypeConst" #-}
+
+newtype SomeOtherNewType = SomeOtherNewTypeConst String
+{-# DEPRECATED SomeOtherNewType "SomeOtherNewType" #-}
+{-# DEPRECATED SomeOtherNewTypeConst "SomeOtherNewTypeConst" #-}
diff --git a/html-test/src/DeprecatedReExport.hs b/html-test/src/DeprecatedReExport.hs
new file mode 100644
index 00000000..f851e2ff
--- /dev/null
+++ b/html-test/src/DeprecatedReExport.hs
@@ -0,0 +1,16 @@
+-- |
+-- What is tested here:
+--
+-- * Deprecation messages are shown for re-exported items.
+--
+module DeprecatedReExport (
+-- * Re-exported from an other module
+ foo
+-- * Re-exported from an other package
+-- | Not yet working, see <http://trac.haskell.org/haddock/ticket/223>
+-- , isEmptyChan
+,
+) where
+
+import DeprecatedFunction
+import Control.Concurrent.Chan
diff --git a/html-test/src/DeprecatedRecord.hs b/html-test/src/DeprecatedRecord.hs
new file mode 100644
index 00000000..d44499e7
--- /dev/null
+++ b/html-test/src/DeprecatedRecord.hs
@@ -0,0 +1,9 @@
+module DeprecatedRecord where
+
+-- | type Foo
+data Foo = Foo {
+ fooName :: String -- ^ some name
+, fooValue :: Int -- ^ some value
+}
+
+{-# DEPRECATED fooValue "do not use this" #-}
diff --git a/html-test/src/DeprecatedTypeFamily.hs b/html-test/src/DeprecatedTypeFamily.hs
new file mode 100644
index 00000000..70473bb8
--- /dev/null
+++ b/html-test/src/DeprecatedTypeFamily.hs
@@ -0,0 +1,9 @@
+{-# LANGUAGE TypeFamilies #-}
+module DeprecatedTypeFamily where
+
+-- | some documentation
+data family SomeTypeFamily k :: * -> *
+{-# DEPRECATED SomeTypeFamily "SomeTypeFamily" #-}
+
+data family SomeOtherTypeFamily k :: * -> *
+{-# DEPRECATED SomeOtherTypeFamily "SomeOtherTypeFamily" #-}
diff --git a/html-test/src/DeprecatedTypeSynonym.hs b/html-test/src/DeprecatedTypeSynonym.hs
new file mode 100644
index 00000000..34df47da
--- /dev/null
+++ b/html-test/src/DeprecatedTypeSynonym.hs
@@ -0,0 +1,9 @@
+
+module DeprecatedTypeSynonym where
+
+-- | some documentation
+type TypeSyn = String
+{-# DEPRECATED TypeSyn "TypeSyn" #-}
+
+type OtherTypeSyn = String
+{-# DEPRECATED OtherTypeSyn "OtherTypeSyn" #-}
diff --git a/html-test/src/DeprecationMessageParseError.hs b/html-test/src/DeprecationMessageParseError.hs
new file mode 100644
index 00000000..2f8fb492
--- /dev/null
+++ b/html-test/src/DeprecationMessageParseError.hs
@@ -0,0 +1,12 @@
+-- |
+-- What is tested here:
+--
+-- * If parsing of a deprecation message fails, the message is included
+-- verbatim.
+--
+module DeprecationMessageParseError where
+
+-- | some documentation for foo
+foo :: Int
+foo = 23
+{-# DEPRECATED foo "use @bar instead" #-}
diff --git a/html-test/src/Examples.hs b/html-test/src/Examples.hs
new file mode 100644
index 00000000..c8c450f1
--- /dev/null
+++ b/html-test/src/Examples.hs
@@ -0,0 +1,39 @@
+module Examples where
+
+-- | Fibonacci number of given 'Integer'.
+--
+-- Examples:
+--
+-- >>> fib 5
+-- 5
+-- >>> fib 10
+-- 55
+--
+-- >>> fib 10
+-- 55
+--
+-- One more Example:
+--
+-- >>> fib 5
+-- 5
+--
+-- One more Example:
+--
+-- >>> fib 5
+-- 5
+--
+-- Example with an import:
+--
+-- >>> import Data.Char
+-- >>> isSpace 'a'
+-- False
+--
+-- >>> putStrLn "foo\n\nbar"
+-- foo
+-- <BLANKLINE>
+-- bar
+--
+fib :: Integer -> Integer
+fib 0 = 0
+fib 1 = 1
+fib n = fib (n - 1) + fib (n - 2)
diff --git a/html-test/src/FunArgs.hs b/html-test/src/FunArgs.hs
new file mode 100644
index 00000000..b34d84b7
--- /dev/null
+++ b/html-test/src/FunArgs.hs
@@ -0,0 +1,16 @@
+module FunArgs where
+
+f :: forall a. Ord a
+ => Int -- ^ First argument
+ -> a -- ^ Second argument
+ -> Bool -- ^ Third argument
+ -> (a -> a) -- ^ Fourth argument
+ -> () -- ^ Result
+f = undefined
+
+
+g :: a -- ^ First argument
+ -> b -- ^ Second argument
+ -> c -- ^ Third argument
+ -> d -- ^ Result
+g = undefined
diff --git a/html-test/src/GADTRecords.hs b/html-test/src/GADTRecords.hs
new file mode 100644
index 00000000..c77810ad
--- /dev/null
+++ b/html-test/src/GADTRecords.hs
@@ -0,0 +1,12 @@
+{-# LANGUAGE GADTs #-}
+module GADTRecords (H1(..)) where
+
+-- | h1
+data H1 a b where
+ C1 :: H1 a b
+ C2 :: Ord a => [a] -> H1 a a
+ C3 { field :: Int -- ^ hello docs
+ } :: H1 Int Int
+ C4 { field2 :: a -- ^ hello2 docs
+ } :: H1 Int a
+
diff --git a/html-test/src/Hash.hs b/html-test/src/Hash.hs
new file mode 100644
index 00000000..343b69e9
--- /dev/null
+++ b/html-test/src/Hash.hs
@@ -0,0 +1,51 @@
+{- |
+ Implementation of fixed-size hash tables, with a type
+ class for constructing hash values for structured types.
+-}
+module Hash (
+ -- * The @HashTable@ type
+ HashTable,
+
+ -- ** Operations on @HashTable@s
+ new, insert, lookup,
+
+ -- * The @Hash@ class
+ Hash(..),
+ ) where
+
+import Data.Array
+import Prelude hiding (lookup)
+
+-- | A hash table with keys of type @key@ and values of type @val@.
+-- The type @key@ should be an instance of 'Eq'.
+data HashTable key val = HashTable Int (Array Int [(key,val)])
+
+-- | Builds a new hash table with a given size
+new :: (Eq key, Hash key) => Int -> IO (HashTable key val)
+new = undefined
+
+-- | Inserts a new element into the hash table
+insert :: (Eq key, Hash key) => key -> val -> IO ()
+insert = undefined
+
+-- | Looks up a key in the hash table, returns @'Just' val@ if the key
+-- was found, or 'Nothing' otherwise.
+lookup :: Hash key => key -> IO (Maybe val)
+lookup = undefined
+
+-- | A class of types which can be hashed.
+class Hash a where
+ -- | hashes the value of type @a@ into an 'Int'
+ hash :: a -> Int
+
+instance Hash Int where
+ hash = id
+
+instance Hash Float where
+ hash = trunc
+
+instance (Hash a, Hash b) => Hash (a,b) where
+ hash (a,b) = hash a `xor` hash b
+
+trunc = undefined
+xor = undefined
diff --git a/html-test/src/Hidden.hs b/html-test/src/Hidden.hs
new file mode 100644
index 00000000..896da648
--- /dev/null
+++ b/html-test/src/Hidden.hs
@@ -0,0 +1,6 @@
+{-# OPTIONS_HADDOCK hide #-}
+
+module Hidden where
+
+hidden :: Int -> Int
+hidden a = a
diff --git a/html-test/src/HiddenInstances.hs b/html-test/src/HiddenInstances.hs
new file mode 100644
index 00000000..99a6c2fd
--- /dev/null
+++ b/html-test/src/HiddenInstances.hs
@@ -0,0 +1,35 @@
+-- http://trac.haskell.org/haddock/ticket/37
+module HiddenInstances (VisibleClass, VisibleData) where
+
+-- | Should be visible
+class VisibleClass a
+
+-- | Should *not* be visible
+class HiddenClass a
+
+-- | Should *not* be visible
+data HiddenData = HiddenData
+
+-- | Should be visible
+data VisibleData = VisibleData
+
+-- | Should be visible
+instance VisibleClass Int
+
+-- | Should be visible
+instance VisibleClass VisibleData
+
+-- | Should be visible
+instance Num VisibleData
+
+-- | Should *not* be visible
+instance VisibleClass HiddenData
+
+-- | Should *not* be visible
+instance HiddenClass Int
+
+-- | Should *not* be visible
+instance HiddenClass VisibleData
+
+-- | Should *not* be visible
+instance HiddenClass HiddenData
diff --git a/html-test/src/HiddenInstancesA.hs b/html-test/src/HiddenInstancesA.hs
new file mode 100644
index 00000000..f1775208
--- /dev/null
+++ b/html-test/src/HiddenInstancesA.hs
@@ -0,0 +1,17 @@
+{-# OPTIONS_HADDOCK hide #-}
+module HiddenInstancesA where
+
+-- | Should be visible
+class Foo a
+
+-- | Should be visible
+data Bar
+
+-- | Should be visible
+instance Foo Bar
+
+-- | Should *not* be visible
+data Baz
+
+-- | Should *not* be visible
+instance Foo Baz
diff --git a/html-test/src/HiddenInstancesB.hs b/html-test/src/HiddenInstancesB.hs
new file mode 100644
index 00000000..eabf0637
--- /dev/null
+++ b/html-test/src/HiddenInstancesB.hs
@@ -0,0 +1,2 @@
+module HiddenInstancesB (Foo, Bar) where
+import HiddenInstancesA
diff --git a/html-test/src/Hyperlinks.hs b/html-test/src/Hyperlinks.hs
new file mode 100644
index 00000000..34e64448
--- /dev/null
+++ b/html-test/src/Hyperlinks.hs
@@ -0,0 +1,8 @@
+module Hyperlinks where
+
+-- |
+-- A plain URL: <http://example.com/>
+--
+-- A URL with a label: <http://example.com/ some link>
+foo :: Int
+foo = 23
diff --git a/html-test/src/IgnoreExports.hs b/html-test/src/IgnoreExports.hs
new file mode 100644
index 00000000..0321ad02
--- /dev/null
+++ b/html-test/src/IgnoreExports.hs
@@ -0,0 +1,10 @@
+{-# OPTIONS_HADDOCK ignore-exports #-}
+module IgnoreExports (foo) where
+
+-- | documentation for foo
+foo :: Int
+foo = 23
+
+-- | documentation for bar
+bar :: Int
+bar = 23
diff --git a/html-test/src/ModuleWithWarning.hs b/html-test/src/ModuleWithWarning.hs
new file mode 100644
index 00000000..e64d9d7e
--- /dev/null
+++ b/html-test/src/ModuleWithWarning.hs
@@ -0,0 +1,5 @@
+-- | Documentation for "ModuleWithWarning".
+module ModuleWithWarning {-# WARNING "This is an unstable interface. Prefer functions from \"Prelude\" instead!" #-} where
+
+foo :: Int
+foo = 23
diff --git a/html-test/src/NamedDoc.hs b/html-test/src/NamedDoc.hs
new file mode 100644
index 00000000..7c04ba72
--- /dev/null
+++ b/html-test/src/NamedDoc.hs
@@ -0,0 +1,4 @@
+module NamedDoc where
+
+-- $foo bar
+
diff --git a/html-test/src/NoLayout.hs b/html-test/src/NoLayout.hs
new file mode 100644
index 00000000..19b38b1d
--- /dev/null
+++ b/html-test/src/NoLayout.hs
@@ -0,0 +1,12 @@
+
+-- Haddock comments are parsed as separate declarations so we
+-- need to insert a ';' when using them with explicit layout.
+-- This should probably be changed.
+
+module NoLayout where {
+ -- | the function 'g'
+ ;
+ g :: Int;
+ g = undefined
+ }
+
diff --git a/html-test/src/NonGreedy.hs b/html-test/src/NonGreedy.hs
new file mode 100644
index 00000000..f51b55f5
--- /dev/null
+++ b/html-test/src/NonGreedy.hs
@@ -0,0 +1,5 @@
+module NonGreedy where
+
+-- | <url1> <url2>
+f :: a
+f = undefined
diff --git a/html-test/src/Properties.hs b/html-test/src/Properties.hs
new file mode 100644
index 00000000..05930ece
--- /dev/null
+++ b/html-test/src/Properties.hs
@@ -0,0 +1,9 @@
+module Properties where
+
+-- | Fibonacci number of given 'Integer'.
+--
+-- prop> fib n <= fib (n + 1)
+fib :: Integer -> Integer
+fib 0 = 0
+fib 1 = 1
+fib n = fib (n - 1) + fib (n - 2)
diff --git a/html-test/src/PruneWithWarning.hs b/html-test/src/PruneWithWarning.hs
new file mode 100644
index 00000000..bfa55ea2
--- /dev/null
+++ b/html-test/src/PruneWithWarning.hs
@@ -0,0 +1,15 @@
+{-# OPTIONS_HADDOCK prune #-}
+-- |
+-- What is tested here:
+--
+-- * If a binding has a deprecation message but no documentation, it is pruned
+-- when @OPTIONS_HADDOCK prune@ is used.
+--
+module PruneWithWarning (foo, bar) where
+
+foo :: Int
+foo = 23
+{-# DEPRECATED foo "use bar instead" #-}
+
+bar :: Int
+bar = 42
diff --git a/html-test/src/QuasiExpr.hs b/html-test/src/QuasiExpr.hs
new file mode 100644
index 00000000..970759ba
--- /dev/null
+++ b/html-test/src/QuasiExpr.hs
@@ -0,0 +1,34 @@
+{-# LANGUAGE TemplateHaskell #-}
+
+-- Used by QuasiQuote. Example taken from the GHC documentation.
+module QuasiExpr where
+
+import Language.Haskell.TH
+import Language.Haskell.TH.Quote
+
+data Expr = IntExpr Integer
+ | AntiIntExpr String
+ | BinopExpr BinOp Expr Expr
+ | AntiExpr String
+ deriving Show
+
+data BinOp = AddOp
+ | SubOp
+ | MulOp
+ | DivOp
+ deriving Show
+
+eval :: Expr -> Integer
+eval (IntExpr n) = n
+eval (BinopExpr op x y) = (opToFun op) (eval x) (eval y)
+ where
+ opToFun AddOp = (+)
+ opToFun SubOp = (-)
+ opToFun MulOp = (*)
+ opToFun DivOp = div
+
+expr = QuasiQuoter parseExprExp undefined undefined undefined
+
+-- cheating...
+parseExprExp :: String -> Q Exp
+parseExprExp _ = [| BinopExpr AddOp (IntExpr 1) (IntExpr 2) |]
diff --git a/html-test/src/QuasiQuote.hs b/html-test/src/QuasiQuote.hs
new file mode 100644
index 00000000..06762cf9
--- /dev/null
+++ b/html-test/src/QuasiQuote.hs
@@ -0,0 +1,9 @@
+{-# LANGUAGE TemplateHaskell, QuasiQuotes #-}
+
+-- example taken from the GHC documentation
+module QuasiQuote where
+
+import QuasiExpr
+
+val :: Integer
+val = eval [expr|1 + 2|]
diff --git a/html-test/src/SpuriousSuperclassConstraints.hs b/html-test/src/SpuriousSuperclassConstraints.hs
new file mode 100644
index 00000000..d9e43e1c
--- /dev/null
+++ b/html-test/src/SpuriousSuperclassConstraints.hs
@@ -0,0 +1,30 @@
+{-# LANGUAGE EmptyDataDecls, KindSignatures #-}
+-- |
+-- What is tested here:
+--
+-- Due to a change in GHC 7.6.1 we had a bug that superclass contraints were
+-- included in the instances list. Edward K. repported it here:
+--
+-- <http://www.haskell.org/pipermail/haskell-cafe/2012-September/103600.html>
+--
+-- And here is the corresponding theard on glasgow-haskell-users:
+--
+-- <http://www.haskell.org/pipermail/glasgow-haskell-users/2012-September/022914.html>
+--
+-- It has been fixed in:
+--
+-- > 6ccf78e15a525282fef61bc4f58a279aa9c21771
+-- > Fix spurious superclass constraints bug.
+--
+module SpuriousSuperclassConstraints where
+
+import Control.Applicative
+
+data SomeType (f :: * -> *) a
+
+instance Functor (SomeType f) where
+ fmap = undefined
+
+instance Applicative f => Applicative (SomeType f) where
+ pure = undefined
+ (<*>) = undefined
diff --git a/html-test/src/TH.hs b/html-test/src/TH.hs
new file mode 100644
index 00000000..f8178bcb
--- /dev/null
+++ b/html-test/src/TH.hs
@@ -0,0 +1,8 @@
+{-# LANGUAGE TemplateHaskell #-}
+
+module TH where
+
+import Language.Haskell.TH
+
+decl :: Q [Dec]
+decl = [d| f x = x|]
diff --git a/html-test/src/TH2.hs b/html-test/src/TH2.hs
new file mode 100644
index 00000000..ea85e547
--- /dev/null
+++ b/html-test/src/TH2.hs
@@ -0,0 +1,7 @@
+{-# LANGUAGE TemplateHaskell #-}
+
+module TH2 where
+
+import TH
+
+$( decl )
diff --git a/html-test/src/Test.hs b/html-test/src/Test.hs
new file mode 100644
index 00000000..d352f029
--- /dev/null
+++ b/html-test/src/Test.hs
@@ -0,0 +1,422 @@
+-----------------------------------------------------------------------------
+-- |
+-- Module : Test
+-- Copyright : (c) Simon Marlow 2002
+-- License : BSD-style
+--
+-- Maintainer : libraries@haskell.org
+-- Stability : provisional
+-- Portability : portable
+--
+-- This module illustrates & tests most of the features of Haddock.
+-- Testing references from the description: 'T', 'f', 'g', 'Visible.visible'.
+--
+-----------------------------------------------------------------------------
+
+-- This is plain comment, ignored by Haddock.
+
+module Test (
+
+ -- Section headings are introduced with '-- *':
+ -- * Type declarations
+
+ -- Subsection headings are introduced with '-- **' and so on.
+ -- ** Data types
+ T(..), T2, T3(..), T4(..), T5(..), T6(..),
+ N1(..), N2(..), N3(..), N4, N5(..), N6(..), N7(..),
+
+ -- ** Records
+ R(..), R1(..),
+
+ -- | test that we can export record selectors on their own:
+ p, q, u,
+
+ -- * Class declarations
+ C(a,b), D(..), E, F(..),
+
+ -- | Test that we can export a class method on its own:
+ a,
+
+ -- * Function types
+ f, g,
+
+ -- * Auxiliary stuff
+
+ -- $aux1
+
+ -- $aux2
+
+ -- $aux3
+
+ -- $aux4
+
+ -- $aux5
+
+ -- $aux6
+
+ -- $aux7
+
+ -- $aux8
+
+ -- $aux9
+
+ -- $aux10
+
+ -- $aux11
+
+ -- $aux12
+
+ -- | This is some inline documentation in the export list
+ --
+ -- > a code block using bird-tracks
+ -- > each line must begin with > (which isn't significant unless it
+ -- > is at the beginning of the line).
+
+ -- * A hidden module
+ module Hidden,
+
+ -- * A visible module
+ module Visible,
+
+ {-| nested-style doc comments -}
+
+ -- * Existential \/ Universal types
+ Ex(..),
+
+ -- * Type signatures with argument docs
+ k, l, m, o,
+
+ -- * A section
+ -- and without an intervening comma:
+ -- ** A subsection
+
+{-|
+ > a literal line
+
+ $ a non /literal/ line $
+-}
+
+ f',
+
+ withType, withoutType
+ ) where
+
+import Hidden
+import Visible
+import Data.Maybe
+
+bla = Nothing
+
+-- | This comment applies to the /following/ declaration
+-- and it continues until the next non-comment line
+data T a b
+ = A Int (Maybe Float) -- ^ This comment describes the 'A' constructor
+ | -- | This comment describes the 'B' constructor
+ B (T a b, T Int Float) -- ^
+
+-- | An abstract data declaration
+data T2 a b = T2 a b
+
+-- | A data declaration with no documentation annotations on the constructors
+data T3 a b = A1 a | B1 b
+
+-- A data declaration with no documentation annotations at all
+data T4 a b = A2 a | B2 b
+
+-- A data declaration documentation on the constructors only
+data T5 a b
+ = A3 a -- ^ documents 'A3'
+ | B3 b -- ^ documents 'B3'
+
+-- | Testing alternative comment styles
+data T6
+ -- | This is the doc for 'A4'
+ = A4
+ | B4
+ | -- ^ This is the doc for 'B4'
+
+ -- | This is the doc for 'C4'
+ C4
+
+-- | A newtype
+newtype N1 a = N1 a
+
+-- | A newtype with a fieldname
+newtype N2 a b = N2 {n :: a b}
+
+-- | A newtype with a fieldname, documentation on the field
+newtype N3 a b = N3 {n3 :: a b -- ^ this is the 'n3' field
+ }
+
+-- | An abstract newtype - we show this one as data rather than newtype because
+-- the difference isn\'t visible to the programmer for an abstract type.
+newtype N4 a b = N4 a
+
+newtype N5 a b = N5 {n5 :: a b -- ^ no docs on the datatype or the constructor
+ }
+
+newtype N6 a b = N6 {n6 :: a b
+ }
+ -- ^ docs on the constructor only
+
+-- | docs on the newtype and the constructor
+newtype N7 a b = N7 {n7 :: a b
+ }
+ -- ^ The 'N7' constructor
+
+
+class (D a) => C a where
+ -- |this is a description of the 'a' method
+ a :: IO a
+ b :: [a]
+ -- ^ this is a description of the 'b' method
+ c :: a -- c is hidden in the export list
+
+-- ^ This comment applies to the /previous/ declaration (the 'C' class)
+
+class D a where
+ d :: T a b
+ e :: (a,a)
+-- ^ This is a class declaration with no separate docs for the methods
+
+instance D Int where
+ d = undefined
+ e = undefined
+
+-- instance with a qualified class name
+instance Test.D Float where
+ d = undefined
+ e = undefined
+
+class E a where
+ ee :: a
+-- ^ This is a class declaration with no methods (or no methods exported)
+
+-- This is a class declaration with no documentation at all
+class F a where
+ ff :: a
+
+-- | This is the documentation for the 'R' record, which has four fields,
+-- 'p', 'q', 'r', and 's'.
+data R =
+ -- | This is the 'C1' record constructor, with the following fields:
+ C1 { p :: Int -- ^ This comment applies to the 'p' field
+ , q :: forall a . a->a -- ^ This comment applies to the 'q' field
+ , -- | This comment applies to both 'r' and 's'
+ r,s :: Int
+ }
+ | C2 { t :: T1 -> (T2 Int Int)-> (T3 Bool Bool) -> (T4 Float Float) -> T5 () (),
+ u,v :: Int
+ }
+ -- ^ This is the 'C2' record constructor, also with some fields:
+
+-- | Testing different record commenting styles
+data R1
+ -- | This is the 'C3' record constructor
+ = C3 {
+ -- | The 's1' record selector
+ s1 :: Int
+ -- | The 's2' record selector
+ , s2 :: Int
+ , s3 :: Int -- NOTE: In the original examples/Test.hs in Haddock, there is an extra "," here.
+ -- Since GHC doesn't allow that, I have removed it in this file.
+ -- ^ The 's3' record selector
+ }
+
+-- These section headers are only used when there is no export list to
+-- give the structure of the documentation:
+
+-- * This is a section header (level 1)
+-- ** This is a section header (level 2)
+-- *** This is a section header (level 3)
+
+{-|
+In a comment string we can refer to identifiers in scope with
+single quotes like this: 'T', and we can refer to modules by
+using double quotes: "Foo". We can add emphasis /like this/.
+
+ * This is a bulleted list
+
+ - This is the next item (different kind of bullet)
+
+ (1) This is an ordered list
+
+ 2. This is the next item (different kind of bullet)
+
+ [cat] a small, furry, domesticated mammal
+
+ [pineapple] a fruit grown in the tropics
+
+@
+ This is a block of code, which can include other markup: 'R'
+ formatting
+ is
+ significant
+@
+
+> this is another block of code
+
+We can also include URLs in documentation: <http://www.haskell.org/>.
+-}
+
+f :: C a => a -> Int
+
+-- | we can export foreign declarations too
+foreign import ccall g :: Int -> IO CInt
+
+-- | this doc string has a parse error in it: \'
+h :: Int
+h = 42
+
+
+-- $aux1 This is some documentation that is attached to a name ($aux1)
+-- rather than a source declaration. The documentation may be
+-- referred to in the export list using its name.
+--
+-- @ code block in named doc @
+
+-- $aux2 This is some documentation that is attached to a name ($aux2)
+
+-- $aux3
+-- @ code block on its own in named doc @
+
+-- $aux4
+--
+-- @ code block on its own in named doc (after newline) @
+
+{- $aux5 a nested, named doc comment
+
+ with a paragraph,
+
+ @ and a code block @
+-}
+
+-- some tests for various arrangements of code blocks:
+
+{- $aux6
+>test
+>test1
+
+@ test2
+ test3
+@
+-}
+
+{- $aux7
+@
+test1
+test2
+@
+-}
+
+{- $aux8
+>test3
+>test4
+-}
+
+{- $aux9
+@
+test1
+test2
+@
+
+>test3
+>test4
+-}
+
+{- $aux10
+>test3
+>test4
+
+@
+test1
+test2
+@
+-}
+
+-- This one is currently wrong (Haddock 0.4). The @...@ part is
+-- interpreted as part of the bird-tracked code block.
+{- $aux11
+aux11:
+
+>test3
+>test4
+
+@
+test1
+test2
+@
+-}
+
+-- $aux12
+-- > foo
+--
+-- > bar
+--
+
+-- | A data-type using existential\/universal types
+data Ex a
+ = forall b . C b => Ex1 b
+ | forall b . Ex2 b
+ | forall b . C a => Ex3 b -- NOTE: I have added "forall b" here make GHC accept this file
+ | Ex4 (forall a . a -> a)
+
+-- | This is a function with documentation for each argument
+k :: T () () -- ^ This argument has type 'T'
+ -> (T2 Int Int) -- ^ This argument has type 'T2 Int Int'
+ -> (T3 Bool Bool -> T4 Float Float) -- ^ This argument has type @T3 Bool Bool -> T4 Float Float@
+ -> T5 () () -- ^ This argument has a very long description that should
+ -- hopefully cause some wrapping to happen when it is finally
+ -- rendered by Haddock in the generated HTML page.
+ -> IO () -- ^ This is the result type
+
+-- This function has arg docs but no docs for the function itself
+l :: (Int, Int, Float) -- ^ takes a triple
+ -> Int -- ^ returns an 'Int'
+
+-- | This function has some arg docs
+m :: R
+ -> N1 () -- ^ one of the arguments
+ -> IO Int -- ^ and the return value
+
+-- | This function has some arg docs but not a return value doc
+
+-- can't use the original name ('n') with GHC
+newn :: R -- ^ one of the arguments, an 'R'
+ -> N1 () -- ^ one of the arguments
+ -> IO Int
+newn = undefined
+
+
+-- | A foreign import with argument docs
+foreign import ccall unsafe
+ o :: Float -- ^ The input float
+ -> IO Float -- ^ The output float
+
+-- | We should be able to escape this: \#\#\#
+
+-- p :: Int
+-- can't use the above original definition with GHC
+newp :: Int
+newp = undefined
+
+-- | a function with a prime can be referred to as 'f''
+-- but f' doesn't get link'd 'f\''
+f' :: Int
+
+-- | Comment on a definition without type signature
+withoutType = undefined
+
+-- | Comment on a definition with type signature
+withType :: Int
+withType = 1
+
+-- Add some definitions here so that this file can be compiled with GHC
+
+data T1
+f = undefined
+f' = undefined
+type CInt = Int
+k = undefined
+l = undefined
+m = undefined
diff --git a/html-test/src/Ticket112.hs b/html-test/src/Ticket112.hs
new file mode 100644
index 00000000..c9cd5117
--- /dev/null
+++ b/html-test/src/Ticket112.hs
@@ -0,0 +1,9 @@
+{-# LANGUAGE MagicHash #-}
+
+module Ticket112 where
+
+import GHC.Prim
+
+-- | ...given a raw 'Addr#' to the string, and the length of the string.
+f :: a
+f = undefined
diff --git a/html-test/src/Ticket61.hs b/html-test/src/Ticket61.hs
new file mode 100644
index 00000000..26ca287f
--- /dev/null
+++ b/html-test/src/Ticket61.hs
@@ -0,0 +1,3 @@
+module Ticket61 (module Ticket61_Hidden) where
+
+import Ticket61_Hidden
diff --git a/html-test/src/Ticket61_Hidden.hs b/html-test/src/Ticket61_Hidden.hs
new file mode 100644
index 00000000..583c10cd
--- /dev/null
+++ b/html-test/src/Ticket61_Hidden.hs
@@ -0,0 +1,7 @@
+{-# OPTIONS_HADDOCK hide #-}
+
+module Ticket61_Hidden where
+
+class C a where
+ -- | A comment about f
+ f :: a
diff --git a/html-test/src/Ticket75.hs b/html-test/src/Ticket75.hs
new file mode 100644
index 00000000..94a2f115
--- /dev/null
+++ b/html-test/src/Ticket75.hs
@@ -0,0 +1,7 @@
+module Ticket75 where
+
+data a :- b = Q
+
+-- | A reference to ':-'
+f :: Int
+f = undefined
diff --git a/html-test/src/TypeFamilies.hs b/html-test/src/TypeFamilies.hs
new file mode 100644
index 00000000..561f95fd
--- /dev/null
+++ b/html-test/src/TypeFamilies.hs
@@ -0,0 +1,28 @@
+{-# LANGUAGE TypeFamilies #-}
+
+module TypeFamilies where
+
+-- | Type family G
+type family G a :: *
+
+-- | A class with an associated type
+class A a where
+ -- | An associated type
+ data B a :: * -> *
+ -- | A method
+ f :: B a Int
+
+-- | Doc for family
+type family F a
+
+
+-- | Doc for G Int
+type instance G Int = Bool
+type instance G Float = Int
+
+
+instance A Int where
+ data B Int x = Con x
+ f = Con 3
+
+g = Con 5
diff --git a/html-test/src/TypeOperators.hs b/html-test/src/TypeOperators.hs
new file mode 100644
index 00000000..edbb9344
--- /dev/null
+++ b/html-test/src/TypeOperators.hs
@@ -0,0 +1,20 @@
+{-# LANGUAGE TypeOperators #-}
+module TypeOperators (
+ -- * stuff
+ (:-:),
+ (:+:),
+ Op,
+ O(..),
+ biO,
+) where
+
+data a :-: b
+
+data (a :+: b) c
+
+data a `Op` b
+
+newtype (g `O` f) a = O { unO :: g (f a) }
+
+biO :: (g `O` f) a
+biO = undefined
diff --git a/html-test/src/Unicode.hs.disabled b/html-test/src/Unicode.hs.disabled
new file mode 100644
index 00000000..d5bbf445
--- /dev/null
+++ b/html-test/src/Unicode.hs.disabled
@@ -0,0 +1,6 @@
+module Unicode where
+
+-- | γλώσσα
+x :: Int
+x = 1
+
diff --git a/html-test/src/Visible.hs b/html-test/src/Visible.hs
new file mode 100644
index 00000000..cad71931
--- /dev/null
+++ b/html-test/src/Visible.hs
@@ -0,0 +1,3 @@
+module Visible where
+visible :: Int -> Int
+visible a = a