[GHC] #11251: isInstance does not work on Typeable with base-4.8 anymore
GHC
ghc-devs at haskell.org
Sun Oct 22 03:36:57 UTC 2017
#11251: isInstance does not work on Typeable with base-4.8 anymore
-------------------------------------+-------------------------------------
Reporter: songzh | Owner: goldfire
Type: bug | Status: new
Priority: normal | Milestone:
Component: Template Haskell | Version: 7.10.1
Resolution: | Keywords: Typeable,
| isInstance
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: None/Unknown | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by songzh):
I also find it is allowed to derive `Typeable` class several times for one
data type.
I am no with GHC 8.2
{{{
{-# LANGUAGE DeriveDataTypeable, StandaloneDeriving #-}
import Data.Typeable
data TT = TT
deriving instance Typeable TT
-- allowed to derive twice.
deriving instance Typeable TT
deriving instance Show TT
-- Not allowed to derive twice
-- deriving instance Show TT
}}}
Should this be allowed? Or they are the same problem with this ticket. I
speculate these are the same problem since GHC does not know `TT` is
already an instance of `Typeable` or not after the first time of deriving.
Do I need to open another ticket for this problem?
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11251#comment:3>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list