[commit: ghc] master: Use pprTypeForUser when printing kinds in ghci (65e4195)

Simon Peyton Jones simonpj at microsoft.com
Thu Jan 24 14:22:54 CET 2013


Repository : ssh://darcs.haskell.org//srv/darcs/ghc

On branch  : master

http://hackage.haskell.org/trac/ghc/changeset/65e41952841e2c7deb83a5a3d1a62215524090f8

>---------------------------------------------------------------

commit 65e41952841e2c7deb83a5a3d1a62215524090f8
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date:   Tue Jan 22 17:34:30 2013 +0000

    Use pprTypeForUser when printing kinds in ghci

>---------------------------------------------------------------

 ghc/InteractiveUI.hs |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/ghc/InteractiveUI.hs b/ghc/InteractiveUI.hs
index 9327546..bc85b45 100644
--- a/ghc/InteractiveUI.hs
+++ b/ghc/InteractiveUI.hs
@@ -1420,7 +1420,9 @@ kindOfType norm str
   = handleSourceError GHC.printException
   $ do
        (ty, kind) <- GHC.typeKind norm str
-       printForUser $ vcat [ text str <+> dcolon <+> ppr kind
+       dflags <- getDynFlags
+       let pefas = gopt Opt_PrintExplicitForalls dflags
+       printForUser $ vcat [ text str <+> dcolon <+> pprTypeForUser pefas kind
                            , ppWhen norm $ equals <+> ppr ty ]
 
 





More information about the ghc-commits mailing list