On Mon, 2010-11-22 at 14:48 +0800, Magicloud Magiclouds wrote:
> (+) :: A -> A -> A
> (+) a b =
>   A (elem1 a + elem1 b) (elem2 a + elem2 b) -- I got errors here, for
> the (+) is ambiguous. 

That's because (+) is implicitly imported from the Prelude. If you

    import Prelude hiding ((+))

the error disappears.

Sebastian


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

Reply via email to