[GHC] #7066: isInstance does not work for compound types
GHC
cvs-ghc at haskell.org
Mon Jul 16 13:56:01 CEST 2012
#7066: isInstance does not work for compound types
---------------------------------+------------------------------------------
Reporter: edsko | Owner: simonpj
Type: bug | Status: new
Priority: normal | Milestone:
Component: Template Haskell | Version: 7.4.2
Keywords: | Os: Unknown/Multiple
Architecture: Unknown/Multiple | Failure: None/Unknown
Difficulty: Unknown | Testcase:
Blockedby: | Blocking:
Related: |
---------------------------------+------------------------------------------
Changes (by simonpj):
* owner: => simonpj
* difficulty: => Unknown
Comment:
That's true, and currently so by design. What if you did want to ask "is
there an instance for pairs?" You could try making up fresh type
variables 'x' and 'y', say, but then with the behaviour you were expecting
it would try to find an instance for `(Show x)`, fail, and hence return an
empty list.
It should be better documented, I agree, but I'm not sure what alternative
behaviour would make sense.
I need review and commit Reiner's patches from #5469, but then I'll add
the docs.
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/7066#comment:1>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the Glasgow-haskell-bugs
mailing list