[Haskell-beginners] Ensuring consistency in typeclass instances?

Brent Yorgey byorgey at seas.upenn.edu
Wed Nov 26 15:04:00 EST 2008

On Wed, Nov 26, 2008 at 05:04:52PM +0000, Colin Paul Adams wrote:
> >>>>> "Brent" == Brent Yorgey <byorgey at seas.upenn.edu> writes:
> I don't see why. Eiffel is strongly typed too. But current compiler
> technology doesn't necessarily permit us to check all we would like
> statically (as you say below).
> It seems to me, having read further, that QuickCheck does just this
> (and is an answer to my own original question). 

True, I should have mentioned QuickCheck in my previous email.  It's
not *quite* the same thing -- in particular, it tests properties you
specify on randomly generated values, rather than testing the actual
values which occur at runtime.  But in many cases that's just as good,
and has the additional benefit that it separates the property testing
from execution -- so you can have confidence in certain semantic
properties without the possibility of run-time exceptions.


More information about the Beginners mailing list