<div dir="ltr">Thank you very much!<div>That is exactly what I want.</div><div class="gmail_extra"><div><div dir="ltr"><div><br></div><div>Best,</div><div>Ke</div></div></div><br><div class="gmail_quote">On Fri, Apr 11, 2014 at 2:43 PM, Magnus Therning <span dir="ltr"><<a href="mailto:magnus@therning.org" target="_blank">magnus@therning.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="">On Fri, Apr 11, 2014 at 12:50:45PM -0400, ke dou wrote:<br>
> instance Coercible (MyOption a) where<br>
>   type Return (MyOption a) = Prelude.Maybe a<br>
>   toHaskell (Some a) = Prelude.Just a<br>
>   toHaskell None = Prelude.Nothing<br>
<br>
</div>The basic issue has been solved in another thread, but wouldn't you<br>
want this one to be something like this:<br>
<br>
instance Coercible a => Coercible (MyOption a) where<br>
    type Return (MyOption a) = Prelude.Maybe (Return a)<br>
    toHaskell (Some a) = Prelude.Just (toHaskell a)<br>
    toHaskell None = Prelude.Nothing<br>
<span class="HOEnZb"><font color="#888888"><br>
/M<br>
<br>
--<br>
Magnus Therning                      OpenPGP: 0xAB4DFBA4<br>
email: <a href="mailto:magnus@therning.org">magnus@therning.org</a>   jabber: <a href="mailto:magnus@therning.org">magnus@therning.org</a><br>
twitter: magthe               <a href="http://therning.org/magnus" target="_blank">http://therning.org/magnus</a><br>
<br>
What gets measured, gets done.<br>
     -- Tom Peters<br>
</font></span><br>_______________________________________________<br>
Beginners mailing list<br>
<a href="mailto:Beginners@haskell.org">Beginners@haskell.org</a><br>
<a href="http://www.haskell.org/mailman/listinfo/beginners" target="_blank">http://www.haskell.org/mailman/listinfo/beginners</a><br>
<br></blockquote></div><br></div></div>