[GHC] #7910: ConstraintKinds and reifyInstances
GHC
cvs-ghc at haskell.org
Wed May 15 00:14:06 CEST 2013
#7910: ConstraintKinds and reifyInstances
----------------------------------------+-----------------------------------
Reporter: elliottt | Owner:
Type: bug | Status: new
Priority: normal | Component: Compiler
Version: 7.6.3 | Keywords: ConstraintKinds, TemplateHaskell
Os: Unknown/Multiple | Architecture: Unknown/Multiple
Failure: Incorrect result at runtime | Blockedby:
Blocking: | Related:
----------------------------------------+-----------------------------------
reifyInstances doesn't appear to know how to deal with a constraint that
is just an alias. For example, the following prints (True,False):
{{{
{-# LANGUAGE ConstraintKinds #-}
{-# LANGUAGE TemplateHaskell #-}
import Language.Haskell.TH
import Language.Haskell.TH.Syntax
class C a
instance C Int
type D a = C a
main = print $(
do isCInst <- isInstance ''C [ConT ''Int]
isDInst <- isInstance ''D [ConT ''Int]
lift (isCInst,isDInst))
}}}
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/7910>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list