Skip to content

Poor error message for kind error

A kind error can lead to the following poor error msg:

tcfail132.hs:30:51:
    Kind error: Expecting kind `k_a18s -> k_a18w -> 
k_a18A -> *',
		but `DUnit t' has kind `k_a18s -> 
k_a18w -> *'
    In the type synonym declaration for `LiftObject'


The source program is

newtype Object f' f t o1 o2  = Object (f' t o1 -> f t o2)
type DUnit t o1 o2       = ()

type T f g t o1 o2  = Either (f t o1 o2) (g t o1 o2)

type LiftObject t f' f         = T (Object f' f t) (DUnit t)
Edited by Simon Marlow
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information