these warning are supposed to be opt-in at the use sites,
aren't they?

As I read it, Phil's suggestion of a FORBIDINSTANCE language extension would be opt-in per module. Lennart's suggestion of attaching warnings to methods in the instance does not seem opt-in. Lennart, have I misinterpreted?

People have circulated somewhat convincing examples that show how these
Functor instances lead to real bugs.

And there are those who are fine with these instances, too. You could imagine many more disagreements which are a consequence of polymorphism. So this feels more like a code-style/linting issue to me, and I think that using a tool like HLint would be more appropriate than introducing a language extension or other change to GHC.



On Thu, Feb 25, 2016 at 1:35 PM, Kosyrev Serge <_deepfire@feelingofgreen.ru> wrote:
Mark Roberts <markandrusroberts@gmail.com> writes:
> Perhaps such warnings could be added to a tool like HLint? I do not
> think they belong in GHC.

People have circulated somewhat convincing examples that show how these
Functor instances lead to real bugs.

I doubt they would agree.

Besides -- these warning are supposed to be opt-in at the use sites,
aren't they?

--
с уважениeм / respectfully,
Косырев Сергей