[GHC] #9444: -ddump-deriv doesn't dump failed newtype-deriving

GHC ghc-devs at haskell.org
Thu Aug 14 12:28:00 UTC 2014


#9444: -ddump-deriv doesn't dump failed newtype-deriving
-------------------------------------+-------------------------------------
       Reporter:  goldfire           |                   Owner:
           Type:  bug                |                  Status:  new
       Priority:  normal             |               Milestone:
      Component:  Compiler           |                 Version:  7.8.2
       Keywords:                     |        Operating System:
   Architecture:  Unknown/Multiple   |  Unknown/Multiple
     Difficulty:  Unknown            |         Type of failure:
     Blocked By:                     |  None/Unknown
Related Tickets:                     |               Test Case:
                                     |                Blocking:
                                     |  Differential Revisions:
-------------------------------------+-------------------------------------
 When I say

 {{{#!hs
 {-# LANGUAGE GeneralizedNewtypeDeriving, TypeFamilies #-}
 {-# OPTIONS_GHC -ddump-deriv #-}

 type family F a
 type instance F Int = Bool

 class C a where
   meth :: a -> F a

 instance C Int where
   meth = (> 0)

 newtype Age = MkAge Int
   deriving C
 }}}

 I get an error (which I should), but I don't get the derived `C` instance,
 as requested by `-ddump-deriv`. The output should include this helpful
 information.

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


More information about the ghc-tickets mailing list