#7368: kindFunResult panic in the
----------------------------------------+-----------------------------------
    Reporter:  ChrisN                   |       Owner:                          
   
        Type:  bug                      |      Status:  new                     
   
    Priority:  normal                   |   Milestone:                          
   
   Component:  Compiler (Type checker)  |     Version:  7.6.1                   
   
    Keywords:  Kinds, kindfunresult     |          Os:  Unknown/Multiple        
   
Architecture:  Unknown/Multiple         |     Failure:  Compile-time crash      
   
  Difficulty:  Unknown                  |    Testcase:  
typecheck/should_fail/T7368
   Blockedby:                           |    Blocking:                          
   
     Related:                           |  
----------------------------------------+-----------------------------------

Comment(by simonpj@…):

 commit be5cc2e33aa8e54299527af9b91e659d54c4cde5
 {{{
 Author: Simon Peyton Jones <simo...@microsoft.com>
 Date:   Wed Dec 19 23:49:47 2012 +0000

     Fix TcUnify.matchExpectedTyConApp so that it returns types of
 compatible kinds

     This fixes Trac #7368. The problem was that we were matching
        Bad w ~ f (Bad f)
     where (f :: * -> *).  Thta leads to (w ~ Bad f), which is
     ill-kinded, but matchExpectedTyConApp was returning the (Bad f)
     as the argument type, and that was being used to instanatiate
     w in the data constructor type, which is very bad.

     The code also becomes simpler and easier to understand, which is
     an excellent thing.

  compiler/typecheck/TcUnify.lhs |   81
 ++++++++++++++++++++--------------------
  1 files changed, 40 insertions(+), 41 deletions(-)
 }}}

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

_______________________________________________
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to