[commit: ghc] wip/ttypeable: Render TYPE 'PtrRepLifted as * (2c406cb)

git at git.haskell.org git at git.haskell.org
Mon Jun 6 11:12:58 UTC 2016


Repository : ssh://git@git.haskell.org/ghc

On branch  : wip/ttypeable
Link       : http://ghc.haskell.org/trac/ghc/changeset/2c406cb3fc2784f4980f706bcc6a96316f41e9c0/ghc

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

commit 2c406cb3fc2784f4980f706bcc6a96316f41e9c0
Author: Ben Gamari <ben at smart-cactus.org>
Date:   Thu Mar 17 01:02:39 2016 +0100

    Render TYPE 'PtrRepLifted as *


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

2c406cb3fc2784f4980f706bcc6a96316f41e9c0
 libraries/base/Data/Typeable/Internal.hs | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/libraries/base/Data/Typeable/Internal.hs b/libraries/base/Data/Typeable/Internal.hs
index 2053adb..baedc64 100644
--- a/libraries/base/Data/Typeable/Internal.hs
+++ b/libraries/base/Data/Typeable/Internal.hs
@@ -320,6 +320,8 @@ typeRepXFingerprint (TypeRepX t) = typeRepFingerprint t
 
 instance Show (TypeRep (a :: k)) where
   showsPrec _ rep
+    | Just HRefl <- rep `eqTypeRep` (typeRep :: TypeRep *) =
+      showChar '*'
     | isListTyCon tc, [ty] <- tys =
       showChar '[' . shows ty . showChar ']'
     | isTupleTyCon tc =



More information about the ghc-commits mailing list