default instance for IsString

Henrik Nilsson nhn at Cs.Nott.AC.UK
Wed Apr 25 12:03:49 CEST 2012


Hi,

On 04/25/2012 09:15 AM, Yitzchak Gale wrote:
> Because
> all other uses of OverloadedStrings that I have
> seen, and there are many, are ill-advised in my
> opinion. They all should have been quasiquoters.

But the problem here is that reasonable people may choose to
disagree as to what is ill-advised or not.

Thus, rather than generalising the existing approach to
overloaded literals in the most straightforward way possible
to strings, the argument is that overloaded string literals
need to be handled differently due to a fundamentally
subjective argument about what is ill-advised or not,
and how overloaded strings might be "abused" unless
there is some special checking in place.

I'm not saying that partial instances of "fromString" is a good
idea. In fact, I'm prepared to believe those who say that
all instances of this they have come across are ill-advised.
But that is not to say that it necessarily always has to be a bad
idea.

Thus, it seems to me that a systematic language extension
is preferable for simplicity and as it does not add any
fundamentally new issues, to one which leads to a more involved
design based on subjective arguments about programming style.

Best,

/Henrik

-- 
Henrik Nilsson
School of Computer Science
The University of Nottingham
nhn at cs.nott.ac.uk



More information about the Glasgow-haskell-users mailing list