X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Fcompiler%2Futils%2FPprStyle.lhs;h=dfb4ec27ad596f9d615f069249b76393d9f6e022;hb=7a3bd641457666e10d0a47be9f22762e03defbf0;hp=b8ee2ed8ea30eca4ccc75754e249202bff7bd8c8;hpb=f65044d135ef61bee82a6c9767235f6780bdf00e;p=ghc-hetmet.git diff --git a/ghc/compiler/utils/PprStyle.lhs b/ghc/compiler/utils/PprStyle.lhs index b8ee2ed..dfb4ec2 100644 --- a/ghc/compiler/utils/PprStyle.lhs +++ b/ghc/compiler/utils/PprStyle.lhs @@ -8,7 +8,7 @@ module PprStyle ( PprStyle(..), - codeStyle, + codeStyle, ifaceStyle, showUserishTypes ) where @@ -39,19 +39,22 @@ style). The most likely ones are variations on how much type info is shown. The following test decides whether or not we are actually generating -code (either C or assembly). +code (either C or assembly), or generating interface files. \begin{code} codeStyle :: PprStyle -> Bool codeStyle PprForC = True codeStyle (PprForAsm _ _) = True codeStyle _ = False + +ifaceStyle :: PprStyle -> Bool +ifaceStyle PprInterface = True +ifaceStyle other = False \end{code} \begin{code} -- True means types like (Eq a, Text b) => a -> b -- False means types like _forall_ a b => Eq a -> Text b -> a -> b showUserishTypes PprForUser = True -showUserishTypes PprInterface = True showUserishTypes other = False \end{code}