[Haskell-beginners] How to override a type class instance ?

Nadir Sampaoli nadirsampaoli at gmail.com
Sat Oct 18 12:00:00 UTC 2014


Hi,
> say, I am not happy with the Show instances of arrays, e.g.

You usually wrap the data type in a newtype and use
GeneralizedNewtypeDeriving to derive the classes you want to keep. Then
write custom instances for the type classes you want to override.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/beginners/attachments/20141018/1e1503a1/attachment.html>


More information about the Beginners mailing list