aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNeil Mitchell <unknown>2008-12-18 15:39:39 +0000
committerNeil Mitchell <unknown>2008-12-18 15:39:39 +0000
commitc0a56f6b01304105eb272e27e8ab890ba4f4be93 (patch)
tree5b35db6b2b6d36e0a1cc21928a346770b0e5fda4
parent0cf6fc670da338a58e103e1324f934139bca8aa3 (diff)
Try and find a better package name than "main" for Hoogle, goes wrong when working on an executable rather than a library
-rw-r--r--src/Main.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Main.hs b/src/Main.hs
index 8f3895bd..686e9237 100644
--- a/src/Main.hs
+++ b/src/Main.hs
@@ -301,7 +301,8 @@ render flags ifaces installedIfaces = do
copyHtmlBits odir libdir css_file
when (Flag_Hoogle `elem` flags) $ do
- ppHoogle pkgName pkgVer title prologue visibleIfaces odir
+ let pkgName2 = if pkgName == "main" && title /= [] then title else pkgName
+ ppHoogle pkgName2 pkgVer title prologue visibleIfaces odir
-------------------------------------------------------------------------------