Update Overlapping instances error message.#3084
Conversation
LiamGoodacre
left a comment
There was a problem hiding this comment.
Thanks! Could you also add yourself to the contributors file?
src/Language/PureScript/Errors.hs
Outdated
| , line "Overlapping type class instances can lead to different behavior based on the order of module imports, and for that reason are not recommended." | ||
| , line "They may be disallowed completely in a future version of the compiler." | ||
| , indent $ paras (map (line . showQualified showIdent) ds) | ||
| , line "Overlapping type class instances can lead to different behavior based on the order of module imports, and for that reason are disallowed." |
There was a problem hiding this comment.
I'm wondering if there is any point in mentioning the order of module imports bit. Given that they are supposed to be disallowed anyway, you're not supposed to be able to observe the described "different behavior" because you'd just see this error message. (Although the overlap check does need improving so that it catches all scenarios).
There was a problem hiding this comment.
I'm also tempted to get rid of this line. We can give a more detailed explanation on the wiki.
There was a problem hiding this comment.
Thanks guys for comments!
I removed the line with the hint why overlapping instances are bad and added myself to contributors.
(Although the overlap check does need improving so that it catches all scenarios).
If there is something else should be done outside of the file it's probably easier to close a PR. Since I need pointers of how to do that.
|
Thank you, guys 😉 |
Fixes #3071.