[GHC] #9827: void does not use <$

GHC ghc-devs at haskell.org
Sun Nov 23 00:34:59 UTC 2014


#9827: void does not use <$
-------------------------------------+-------------------------------------
       Reporter:  dfeuer             |                   Owner:  dfeuer
           Type:  task               |                  Status:  new
       Priority:  normal             |               Milestone:  7.10.1
      Component:  Core Libraries     |                 Version:  7.9
       Keywords:                     |        Operating System:
   Architecture:  Unknown/Multiple   |  Unknown/Multiple
     Difficulty:  Easy (less than 1  |         Type of failure:  Runtime
  hour)                              |  performance bug
     Blocked By:                     |               Test Case:
Related Tickets:                     |                Blocking:
                                     |  Differential Revisions:  Phab:D521
-------------------------------------+-------------------------------------
 `Data.Functor.void` is currently defined as

 {{{#!hs
 void = fmap (const ())
 }}}

 Some `Functor` instances have an optimized `<$`, so this should be

 {{{#!hs
 void x = () <$ x
 }}}

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


More information about the ghc-tickets mailing list