From: panne Date: Mon, 29 May 2000 01:20:41 +0000 (+0000) Subject: [project @ 2000-05-29 01:20:41 by panne] X-Git-Tag: Approximately_9120_patches~4355 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=2e41c78179913c2763403bbe7dd1697abf8da791;p=ghc-hetmet.git [project @ 2000-05-29 01:20:41 by panne] Hopefully this is a better place to fix the printing of litlits in interface files... *please merge* --- diff --git a/ghc/compiler/hsSyn/HsCore.lhs b/ghc/compiler/hsSyn/HsCore.lhs index 838bbb3..c7f3c2f 100644 --- a/ghc/compiler/hsSyn/HsCore.lhs +++ b/ghc/compiler/hsSyn/HsCore.lhs @@ -191,7 +191,7 @@ pprUfExpr :: Outputable name => (SDoc -> SDoc) -> UfExpr name -> SDoc pprUfExpr add_par (UfVar v) = ppr v pprUfExpr add_par (UfLit l) = ppr l -pprUfExpr add_par (UfLitLit l ty) = ppr l +pprUfExpr add_par (UfLitLit l ty) = add_par (hsep [ptext SLIT("__litlit"), pprFSAsString l, pprParendHsType ty]) pprUfExpr add_par (UfCCall cc ty) = braces (pprCCallOp cc <+> ppr ty) pprUfExpr add_par (UfType ty) = char '@' <+> pprParendHsType ty pprUfExpr add_par (UfLam b body) = add_par (hsep [char '\\', ppr b, ptext SLIT("->"), pprUfExpr noParens body]) @@ -229,7 +229,7 @@ instance Outputable name => Outputable (UfNote name) where instance Outputable name => Outputable (UfConAlt name) where ppr UfDefault = text "__DEFAULT" ppr (UfLitAlt l) = ppr l - ppr (UfLitLitAlt l ty) = ppr l + ppr (UfLitLitAlt l ty) = parens (hsep [ptext SLIT("__litlit"), pprFSAsString l, pprParendHsType ty]) ppr (UfDataAlt d) = ppr d instance Outputable name => Outputable (UfBinder name) where