Aaron McDaid wrote:
> This code experiments with "Int", "Float" and "(Num a) => a", and I
> tried to print x*2 and x/2 for each. (4::Int)/2 isn't allowed because /
> isn't defined for Ints.
More exactly: (/) is a member function of the Fractional class, and Int is not
an instance of this class.
Hi,
I think the following might help a little in understanding the
monomorphic restriction (which I don't fully understand myself). I'm a
bit of a newbie so apologies in advance if I've made a mistake or if my
description isn't as useful to others as it seems to me. I've been
following a threa