From 3d3b5c8754225dd18a0423583ed5e37746ddf465 Mon Sep 17 00:00:00 2001 From: panne Date: Mon, 4 Aug 2003 10:18:24 +0000 Subject: [haddock @ 2003-08-04 10:18:24 by panne] Don't print parentheses around one-element contexts --- src/HaddockHtml.hs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/HaddockHtml.hs b/src/HaddockHtml.hs index 062b29c0..f6a9bdd5 100644 --- a/src/HaddockHtml.hs +++ b/src/HaddockHtml.hs @@ -758,11 +758,12 @@ ppFunSig summary nm ty0 doc -- ---------------------------------------------------------------------------- -- Types and contexts -ppHsAsst :: (HsQName,[HsType]) -> Html +ppHsAsst :: HsAsst -> Html ppHsAsst (c,args) = ppHsQName c <+> hsep (map ppHsAType args) ppHsContext :: HsContext -> Html ppHsContext [] = empty +ppHsContext [asst] = ppHsAsst asst ppHsContext context = parenList (map ppHsAsst context) ppHsForAll :: Maybe [HsName] -> HsContext -> Html -- cgit v1.2.3