overlapping instances and constraints

Ben Rudiak-Gould Benjamin.Rudiak-Gould at cl.cam.ac.uk
Tue Feb 28 16:22:41 EST 2006

Simon Peyton-Jones wrote:
> - A program that type checks can have its meaning changed by adding an
> instance declaration
> - Similarly adding "import M()" can change the meaning of a program (by
> changing which instances are visible
> - Haskell would need to be a lot more specific about exactly where
> context reduction takes place.

I think all of these problems would go away if overlap was permitted within 
a module but forbidden across modules. Are there uses of overlapping 
instances for which this isn't flexible enough?

-- Ben

More information about the Haskell-prime mailing list