On Mon, 19 Mar 2007, Ian Lynagh wrote:

> On Sun, Mar 18, 2007 at 05:47:21PM +0000, C Rodrigues wrote:
> > Type synonyms aren't applied as I would expect during kind checking.
> > What's going on here?
> >
> > type WithList a b = b [a]
> > type FooPair a b = (b, a -> b)
> >
> > -- error: `WithList' is applied to too many type arguments
> > ints1 :: WithList Int FooPair [Int]
> > ints1 = ([1], id)
>
> That's caused by kind defaulting, as bulat said.

In Haskell 98 it is not allowed to define type synonymes in a partially
applied manner. That is, there is no alternative to

type WithList a b c = b [a] c
_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to