[GHC] #6020: "Couldn't match kind" with free type variables and PolyKinds
GHC
cvs-ghc at haskell.org
Thu Apr 26 13:44:00 CEST 2012
#6020: "Couldn't match kind" with free type variables and PolyKinds
----------------------------------------+-----------------------------------
Reporter: atnnn | Owner:
Type: feature request | Status: closed
Priority: normal | Milestone:
Component: Compiler | Version: 7.5
Resolution: fixed | Keywords:
Os: Unknown/Multiple | Architecture: Unknown/Multiple
Failure: GHC rejects valid program | Difficulty: Unknown
Testcase: polykinds/T6020, T6020a | Blockedby:
Blocking: | Related:
----------------------------------------+-----------------------------------
Changes (by simonpj):
* status: new => closed
* testcase: polykinds/T6020 => polykinds/T6020, T6020a
* resolution: => fixed
Comment:
Urgh. A one-character typo! Fixed by
{{{
commit 4cc882650af6a4fadb30706f21e987edb846bcc3
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date: Thu Apr 26 09:29:15 2012 +0100
Fix a one-character typo (kv1 should be kv2!)
Fixes Trac #6020, #6044
>---------------------------------------------------------------
compiler/typecheck/TcUnify.lhs | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/compiler/typecheck/TcUnify.lhs
b/compiler/typecheck/TcUnify.lhs index 1729dcd..6e4d128 100644
--- a/compiler/typecheck/TcUnify.lhs
+++ b/compiler/typecheck/TcUnify.lhs
@@ -1119,7 +1119,7 @@ uKVar isFlipped unify_kind eq_res kv1 k2
| TyVarTy kv2 <- k2, kv1 == kv2
= return eq_res
- | TyVarTy kv2 <- k2, isTcTyVar kv1, isMetaTyVar kv2
+ | TyVarTy kv2 <- k2, isTcTyVar kv2, isMetaTyVar kv2
= uKVar (not isFlipped) unify_kind eq_res kv2 (TyVarTy kv1)
| otherwise = if isFlipped
}}}
I added a new regression test too!
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/6020#comment:5>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the Glasgow-haskell-bugs
mailing list