diff options
Diffstat (limited to 'src/Haddock')
-rw-r--r-- | src/Haddock/Backends/Hoogle.hs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/Haddock/Backends/Hoogle.hs b/src/Haddock/Backends/Hoogle.hs index 5f9a60a9..33d77bef 100644 --- a/src/Haddock/Backends/Hoogle.hs +++ b/src/Haddock/Backends/Hoogle.hs @@ -56,7 +56,11 @@ dropComment [] = [] out :: Outputable a => a -> String -out = unwords . map (dropWhile isSpace) . lines . showSDocUnqual . ppr +out = f . unwords . map (dropWhile isSpace) . lines . showSDocUnqual . ppr + where + f xs | " <document comment>" `isPrefixOf` xs = f $ drop 19 xs + f (x:xs) = x : f xs + f [] = [] typeSig :: String -> [String] -> String |