[email protected]
[Top] [All Lists]

[Haskell-cafe] Infix instance headers

Subject: [Haskell-cafe] Infix instance headers
From: Bas van Dijk
Date: Mon, 21 Dec 2009 22:33:12 +0100
Hello,

What's the reason that infix class declarations and infix constraints
are supported but infix instance heads aren't?

For example the following code from my regions package is allowed but
writing the instance header infix results in a "Malformed instance
header" error:

class (Monad pr, Monad cr) => pr `ParentOf` cr

instance Monad r => ParentOf r r

instance ( Monad cr
         , cr `TypeCast2` RegionT resource s pcr
         , pr `ParentOf` pcr
         )
         => ParentOf pr cr

regards,

Bas
_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

<Prev in Thread] Current Thread [Next in Thread>