[GHC] #13115: missing data instances for IntPtr and WordPtr in base

GHC ghc-devs at haskell.org
Sun Sep 10 13:57:15 UTC 2017


#13115: missing data instances for IntPtr and WordPtr in base
-------------------------------------+-------------------------------------
        Reporter:  carter            |                Owner:  sighingnow
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Compiler          |              Version:  8.0.1
      Resolution:                    |             Keywords:  newcomer
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------
Changes (by RyanGlScott):

 * owner:  (none) => sighingnow


Comment:

 Replying to [comment:4 sighingnow]:
 > Hi, I am a newcomer to ghc-devs mailing list and I volunteer to fix this
 issue.

 Wonderful!

 > Since base-4.10.0.0, the `IntPtr` and `WordPtr` are defined using
 `newtype` rather than `data` (as in base-4.9.1.0), is it enough for this
 issue that putting the following instance declarations to `Data.Data`
 module (with `GeneralizedNewtypeDeriving` enabled) ?
 >
 > {{{#!haskell
 > deriving instance Data IntPtr
 >
 > deriving instance Data WordPtr
 > }}}

 Yes, I think that would work quite nicely.

 Feel free to ask any more questions here if they arise.

-- 
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/13115#comment:5>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list