[GHC] #9790: Produce coercion rules for derived Functor instances

GHC ghc-devs at haskell.org
Tue Nov 11 00:07:31 UTC 2014


#9790: Produce coercion rules for derived Functor instances
-------------------------------------+-------------------------------------
       Reporter:  dfeuer             |                   Owner:
           Type:  feature request    |                  Status:  new
       Priority:  normal             |               Milestone:
      Component:  Compiler           |                 Version:  7.9
       Keywords:  coercion           |        Operating System:
   Architecture:  Unknown/Multiple   |  Unknown/Multiple
     Difficulty:  Unknown            |         Type of failure:  Runtime
     Blocked By:                     |  performance bug
Related Tickets:                     |               Test Case:
                                     |                Blocking:
                                     |  Differential Revisions:
-------------------------------------+-------------------------------------
 I don't ''think'' we do this yet, but I think we probably can. If we
 derive a `Functor` instance, we should, whenever possible and valid,
 produce some sort of `fmap coerce = coerce` rule for that type. This is
 done manually for lists in `GHC.Base`, but I imagine it probably applies
 (much) more generally.

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


More information about the ghc-tickets mailing list