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

git at git.haskell.org git at git.haskell.org
Sun Jan 29 20:19:47 UTC 2017


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

On branch  : wip/ttypeable
Link       : http://ghc.haskell.org/trac/ghc/changeset/3006200420fad41f9f7dd404549301cffb1f4e5e/ghc

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

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

    Render TYPE 'PtrRepLifted as *


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

3006200420fad41f9f7dd404549301cffb1f4e5e
 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 108aa71..8a58d4e 100644
--- a/libraries/base/Data/Typeable/Internal.hs
+++ b/libraries/base/Data/Typeable/Internal.hs
@@ -323,6 +323,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