|
|
|
|
|
by jberryman
4807 days ago
|
|
Defining instances for both someone else's class and someone else's type is considered bad and GHC will warn: http://stackoverflow.com/questions/3079537/orphaned-instance... There are occasions where it can be useful to have a module export an orphan instance for compatibility before it makes it into the more appropriate spot in the standard libs. And you're right you can't have multiple instances for the same type; a newtype wrapper is required. |
|