<font size="2"><span style="background-color:rgba(255,255,255,0)">With <i>UndecidableInstances</i> switchd on it seems to work :-)</span></font><div><font size="2"><span style="-webkit-tap-highlight-color: rgba(26, 26, 26, 0.301961);"><br></span></font></div><div><font size="2"><span style="-webkit-tap-highlight-color: rgba(26, 26, 26, 0.301961);">Thanks for the help!</span></font></div><div><font size="2"><span style="-webkit-tap-highlight-color: rgba(26, 26, 26, 0.301961);"><br></span></font></div><div><font size="2"><span style="-webkit-tap-highlight-color: rgba(26, 26, 26, 0.301961);"> Gabor<br></span></font><br>Em sexta-feira, 31 de julho de 2015, Gabor Greif <<a href="mailto:ggreif@gmail.com">ggreif@gmail.com</a>> escreveu:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">No. I'll switch that on and report back.<div><br></div><div>Thanks,</div><div><br></div><div> Gabor<br><br>Em sexta-feira, 31 de julho de 2015, Simon Peyton Jones <<a href="javascript:_e(%7B%7D,'cvml','simonpj@microsoft.com');" target="_blank">simonpj@microsoft.com</a>> escreveu:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">you need "liberal coverage checking", so UndecidableInstances. Are you doing that?<br>
<br>
| -----Original Message-----<br>
| From: ghc-devs [mailto:<a>ghc-devs-bounces@haskell.org</a>] On Behalf Of<br>
| Richard Eisenberg<br>
| Sent: 31 July 2015 16:10<br>
| To: Gabor Greif<br>
| Cc: ghc-devs<br>
| Subject: Re: Fundep question<br>
|<br>
| Let's rewrite with explicit kind variables, noting that b is also<br>
| poly-kinded:<br>
|<br>
| class Dep k k2 (a :: k) (b :: k2) | a -> b k2<br>
| -- if a determines b, it surely determines k2<br>
|<br>
| instance Dep k * x y => Dep (Maybe k) * (Just x) (Maybe y)<br>
|<br>
| Actually, even with the kinds explicit, it still looks valid to me.<br>
| Post a bug report?<br>
|<br>
| Richard<br>
|<br>
| On Jul 31, 2015, at 9:54 AM, Gabor Greif <<a>ggreif@gmail.com</a>> wrote:<br>
|<br>
| > Hi all,<br>
| ><br>
| > say I want to instantiate<br>
| ><br>
| > class Dep (a :: k) b | a -> b<br>
| ><br>
| > as<br>
| ><br>
| > instance Dep x y => Dep (Just x) (Maybe y)<br>
| ><br>
| > Is this supposed to work? I get "The coverage condition fails"<br>
| errors.<br>
| ><br>
| > For simple cases like<br>
| ><br>
| > instance Dep True Bool<br>
| ><br>
| > etc. it seems to work fine.<br>
| ><br>
| > Thanks and cheers,<br>
| ><br>
| > Gabor<br>
| > _______________________________________________<br>
| > ghc-devs mailing list<br>
| > <a>ghc-devs@haskell.org</a><br>
| > <a href="http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs" target="_blank">http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs</a><br>
|<br>
| _______________________________________________<br>
| ghc-devs mailing list<br>
| <a>ghc-devs@haskell.org</a><br>
| <a href="http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs" target="_blank">http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs</a><br>
</blockquote></div>
</blockquote></div>