aboutsummaryrefslogtreecommitdiff
path: root/src/HaddockUtil.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/HaddockUtil.hs')
-rw-r--r--src/HaddockUtil.hs6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/HaddockUtil.hs b/src/HaddockUtil.hs
index ef02596f..96dc7a0b 100644
--- a/src/HaddockUtil.hs
+++ b/src/HaddockUtil.hs
@@ -385,8 +385,10 @@ isPathSeparator ch =
moduleHtmlFile :: String -> FilePath
moduleHtmlFile mdl =
case Map.lookup (Module mdl) html_xrefs of
- Nothing -> mdl ++ ".html"
- Just fp0 -> pathJoin [fp0, mdl ++ ".html"]
+ Nothing -> mdl' ++ ".html"
+ Just fp0 -> pathJoin [fp0, mdl' ++ ".html"]
+ where
+ mdl' = map (\c -> if c == '.' then '-' else c) mdl
nameHtmlRef :: String -> HsName -> String
nameHtmlRef mdl str = moduleHtmlFile mdl ++ '#':escapeStr (hsAnchorNameStr str)