[Fwd: Re: [Haskell-cafe] Implicit newtype unwrapping]
Holger Siegel
holgersiegel74 at yahoo.de
Wed Dec 2 19:25:37 EST 2009
Am Donnerstag, den 03.12.2009, 01:16 +0100 schrieb Martijn van
Steenbergen:
> So here's a totally wild idea Sjoerd and I came up with.
>
> What if newtypes were unwrapped implicitly?
>
> What advantages and disadvantages would it have?
> In what cases would this lead to ambiguous code?
1)
instance Monoid a => Monoid (Dual a)
2)
instance Monoid (Endo a)
instance Monoid b => Monoid (a -> b)
More information about the Haskell-Cafe
mailing list