Brian Hulley wrote :<br>
&gt; Possibly you meant to write:<br>
&gt;&nbsp; instance IsFoo a =&gt; Class2 a a<br>
&gt;&nbsp; instance Class2 (Bar a) a<br>
<br>
Yes, in principle that illustrates the idea.<br>
However I don't see the major difference from constraining the<br>
'a' to the IsFoo class, as in<br>
&nbsp;<br>
instance IsFoo a =&gt; Class2 (Bar a) a<br>
<br>
This wont automatically imply 'Bar a' to instantiate IsFoo.<br>
<br>
As pointed out, the problem arises due to the fact that it is possible<br>
to write an instance for Bar a, which would then violate the&nbsp; FunDep constraint.<br>
<br>
So, since the compiler does not control this, I'll better remove the FunDep.<br>
<br>
Thanks<br>
/Joel <br><div><span class="gmail_quote"><br>
</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br><br></blockquote></div><br>