[core libraries] Data.Display - Textual representation of Haskell values (was Re: PROPOSAL: Add displayException to Exception typeclass)
Erik Hesselink
hesselink at gmail.com
Mon Nov 10 20:36:26 UTC 2014
On Mon, Nov 10, 2014 at 9:16 PM, Michael Snoyman <michael at snoyman.com> wrote:
>
> On Mon Nov 10 2014 at 9:55:28 PM Roman Cheplyaka <roma at ro-che.info> wrote:
>>
>> On 10/11/14 13:32, Michael Snoyman wrote:
>> > One other question/comment: I'm not convinced that the `String` instance
>> > is
>> > a good thing. It will conflict with any other list instance, unless you
>> > turn on OverlappingInstances (which I hope you don't).
>>
>> I do. Why don't you?
>>
> Just the general aversion to OverlappingInstances. The few times in the past
> I've attempted to use OverlappingInstances to solve a problem, it turned out
> poorly, which has left a bad taste in my mouth.
>
> In this case, I wouldn't want some orphan instance of `instance Display
> [Int]`, for example, changing behavior of my program. That's not a very
> strong reason to be sure; my primary concern is the unforeseen complications
> it will result in.
That's still possible if the instance for [Int] has
OverlappingInstances turned on, even if you personally don't. It has
to be enabled on *either* instance, not on both.
Erik
More information about the Libraries
mailing list