[GHC] #6074: Instance inference failure with GADTs

GHC cvs-ghc at haskell.org
Fri May 4 13:39:42 CEST 2012


#6074: Instance inference failure with GADTs
------------------------------+---------------------------------------------
 Reporter:  goldfire          |          Owner:                  
     Type:  bug               |         Status:  new             
 Priority:  normal            |      Component:  Compiler        
  Version:  7.5               |       Keywords:  GADTs           
       Os:  Unknown/Multiple  |   Architecture:  Unknown/Multiple
  Failure:  None/Unknown      |       Testcase:                  
Blockedby:                    |       Blocking:                  
  Related:                    |  
------------------------------+---------------------------------------------

Comment(by michalt):

 I'm definitely not an expert with type systems, but I don't think GHC can
 do
 that. The problem is that ```a``` can be in fact anything. Consider
 something
 like:
 {{{
 foo :: GADT Char
 foo = undefined

 test = mkString foo
 }}}
 which instance should be called? The one for ```Int``` or ```Bool```?

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/6074#comment:1>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler



More information about the Glasgow-haskell-bugs mailing list