diff options
Diffstat (limited to 'src/Haddock/Backends/Hoogle.hs')
-rw-r--r-- | src/Haddock/Backends/Hoogle.hs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Haddock/Backends/Hoogle.hs b/src/Haddock/Backends/Hoogle.hs index 2cfdcf64..14594569 100644 --- a/src/Haddock/Backends/Hoogle.hs +++ b/src/Haddock/Backends/Hoogle.hs @@ -207,9 +207,11 @@ showInline = unwordsWrap 70 . words . concatMap f where fs = concatMap f f (Str x) = escape x - f (TagInline s xs) = "<"++s++">" ++ fs xs ++ "</"++s++">" + f (TagInline s xs) = "<"++s++">" ++ (if s == "li" then trim else id) (fs xs) ++ "</"++s++">" f x = fs $ asInline x + trim = dropWhile isSpace . reverse . dropWhile isSpace . reverse + showPre :: [Tag] -> [String] showPre = trimFront . trimLines . lines . concatMap f |