X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;ds=sidebyside;f=compiler%2FhsSyn%2FHsDecls.lhs;h=b9f09974a5b1cbe9671f1cda5b611a487d0cc7b6;hb=206b4dec78250efef3cd927d64dc6cbc54a16c3d;hp=572a8422d98eb46af52272028bb1e5c34dde34c6;hpb=17df1af61ee71241d141bfe0455ec78a6bec01e6;p=ghc-hetmet.git diff --git a/compiler/hsSyn/HsDecls.lhs b/compiler/hsSyn/HsDecls.lhs index 572a842..b9f0997 100644 --- a/compiler/hsSyn/HsDecls.lhs +++ b/compiler/hsSyn/HsDecls.lhs @@ -9,6 +9,13 @@ Definitions for: @TyDecl@ and @oCnDecl@, @ClassDecl@, @InstDecl@, @DefaultDecl@ and @ForeignDecl@. \begin{code} +{-# OPTIONS -w #-} +-- The above warning supression flag is a temporary kludge. +-- While working on this module you are encouraged to remove it and fix +-- any warnings in the module. See +-- http://hackage.haskell.org/trac/ghc/wiki/Commentary/CodingStyle#Warnings +-- for details + module HsDecls ( HsDecl(..), LHsDecl, TyClDecl(..), LTyClDecl, InstDecl(..), LInstDecl, DerivDecl(..), LDerivDecl, NewOrData(..), @@ -678,7 +685,7 @@ data ResType name \end{code} \begin{code} -conDeclsNames :: forall name. Eq name => [ConDecl name] -> [Located name] +conDeclsNames :: (Eq name) => [ConDecl name] -> [Located name] -- See tyClDeclNames for what this does -- The function is boringly complicated because of the records -- And since we only have equality, we have to be a little careful @@ -745,10 +752,10 @@ data InstDecl name instance (OutputableBndr name) => Outputable (InstDecl name) where ppr (InstDecl inst_ty binds uprags ats) - = vcat [hsep [ptext SLIT("instance"), ppr inst_ty, ptext SLIT("where")], - nest 4 (ppr ats), - nest 4 (ppr uprags), - nest 4 (pprLHsBinds binds) ] + = vcat [hsep [ptext SLIT("instance"), ppr inst_ty, ptext SLIT("where")] + , nest 4 $ vcat (map ppr ats) + , nest 4 $ vcat (map ppr uprags) + , nest 4 $ pprLHsBinds binds ] -- Extract the declarations of associated types from an instance --