Skip to content

Conflicting typefamily instances not reported with polykinds

GHC fails to report conflicting instances for a open polykinded type family when the two resulting types have different kinds. I would expect conflicts to be detected regardless of the concrete kind of the result.

Minimal Example:

type family Bar a :: k

type instance Bar Int = Int 
--type instance Bar Int = Bool -- Conflict detected
type instance Bar Int = [] -- Conflict NOT detected
Trac metadata
Trac field Value
Version 7.8.3
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Compiler
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information