#6064: InstanceD declaration does not allow for explicit TyVarBndrs
------------------------------+---------------------------------------------
 Reporter:  goldfire          |          Owner:  goldfire                 
     Type:  feature request   |         Status:  new                      
 Priority:  normal            |      Component:  Template Haskell         
  Version:  7.5               |       Keywords:  TemplateHaskell InstanceD
       Os:  Unknown/Multiple  |   Architecture:  Unknown/Multiple         
  Failure:  None/Unknown      |       Testcase:                           
Blockedby:                    |       Blocking:                           
  Related:                    |  
------------------------------+---------------------------------------------
Changes (by goldfire):

  * owner:  => goldfire


Comment:

 I've attached a patch that does the above. This is a breaking change, so
 I'm not convinced it should be made, but I would like an alternative to
 using kind variables in instance declarations with TH. (The other route
 would be to allow the use of undeclared kind variables in the head of an
 instance declaration.)

 One particular potential annoyance with this change is that all type
 variables used in an instance declaration produced in TH are required to
 be declared in the TyVarBndrs. It is conceivable to relax this restriction
 by checking for the declarations and inferring them if they are not there,
 but this idea is not implemented in the patch because it feels, well,
 patchy.

 I have not fully validated nor updated the test cases with respect to this
 change, but would be happy to do so if the change is desired. Please let
 me know if you would like this!

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

_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to