From f6c317bf8828378549d48d68f118fd9f0f919f82 Mon Sep 17 00:00:00 2001 From: Adam Sandberg Eriksson Date: Fri, 3 Jul 2015 15:57:06 +0200 Subject: StrictData: print correct strictness marks --- haddock-api/src/Haddock/Backends/Xhtml/Decl.hs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'haddock-api/src/Haddock/Backends/Xhtml/Decl.hs') diff --git a/haddock-api/src/Haddock/Backends/Xhtml/Decl.hs b/haddock-api/src/Haddock/Backends/Xhtml/Decl.hs index 15bfae08..f01365e9 100644 --- a/haddock-api/src/Haddock/Backends/Xhtml/Decl.hs +++ b/haddock-api/src/Haddock/Backends/Xhtml/Decl.hs @@ -865,9 +865,11 @@ ppDataHeader _ _ _ _ = error "ppDataHeader: illegal argument" ppBang :: HsBang -> Html -ppBang HsNoBang = noHtml -ppBang _ = toHtml "!" -- Unpacked args is an implementation detail, - -- so we just show the strictness annotation +ppBang HsStrict = toHtml "!" +ppBang (HsUnpack {}) = toHtml "!" +ppBang (HsSrcBang _ _ (Just True)) = toHtml "!" +ppBang (HsSrcBang _ _ (Just False)) = toHtml "~" +ppBang _ = noHtml tupleParens :: HsTupleSort -> [Html] -> Html -- cgit v1.2.3