From: Ian Lynagh Date: Sat, 20 Jun 2009 20:48:09 +0000 (+0000) Subject: Unconditionally make a (Show Ptr) instance X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=279ad1298808f05fca5c734dde309dd26596043b;p=ghc-base.git Unconditionally make a (Show Ptr) instance It used to only exist if (WORD_SIZE_IN_BITS == 32 || WORD_SIZE_IN_BITS == 64) --- diff --git a/GHC/Ptr.lhs b/GHC/Ptr.lhs index 7841cf3..8087c77 100644 --- a/GHC/Ptr.lhs +++ b/GHC/Ptr.lhs @@ -145,9 +145,7 @@ castPtrToFunPtr (Ptr addr) = FunPtr addr ------------------------------------------------------------------------ -- Show instances for Ptr and FunPtr --- I have absolutely no idea why the WORD_SIZE_IN_BITS stuff is here -#if (WORD_SIZE_IN_BITS == 32 || WORD_SIZE_IN_BITS == 64) instance Show (Ptr a) where showsPrec _ (Ptr a) rs = pad_out (showHex (wordToInteger(int2Word#(addr2Int# a))) "") where @@ -157,6 +155,5 @@ instance Show (Ptr a) where instance Show (FunPtr a) where showsPrec p = showsPrec p . castFunPtrToPtr -#endif \end{code}