<div dir="ltr">Hi Ziv,<div><br></div><div>Thanks for your comprehensive answer!</div><div><br></div><div>Sincerely,</div><div>Saulo</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Sep 30, 2016 at 10:17 PM, Ziv Scully <span dir="ltr"><<a href="mailto:ziv@mit.edu" target="_blank">ziv@mit.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">The relevant mechanism is `where`. Try something like the following.<span class=""><div><br></div><div>signature A = sig type t end</div><div>signature B = sig type t end</div><div><br></div></span><div>structure C = sig</div><div> structure A1 : A</div> structure B1 : B where type t = A.t<div>end</div><div><br></div><div>This is especially useful for relating types in the input and output signatures of functors:</div><div><br></div><div>functor F(A1 : A) : B where type t = A.t</div><div><br></div><div>You can do the same for any constructor using `where con` instead of `where type`, and you can use multiple `where` statements on the same signature one after the other.</div><div><br></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="h5">On Fri, Sep 30, 2016 at 8:35 PM, Saulo Araujo <span dir="ltr"><<a href="mailto:saulo2@gmail.com" target="_blank">saulo2@gmail.com</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div dir="ltr"><div><div><div><div>Hi,<br><br></div>Does Ur/Web supports sharing types in signatures like in the code below?<br><br>signature A = sig<br> type t<br>end<br><br>signature B = sig<br> type t<br>end<br><br>signature C = sig<br> structure A1 : A<br> structure B1 : B<br> sharing type A1.t = B1.t<br>end<br><br></div>In case it is not supported, is there a way to accomplish something similar? <br><br></div>Sincerely,<br></div>Saulo<br></div>
<br></div></div>______________________________<wbr>_________________<br>
Ur mailing list<br>
<a href="mailto:Ur@impredicative.com" target="_blank">Ur@impredicative.com</a><br>
<a href="http://www.impredicative.com/cgi-bin/mailman/listinfo/ur" rel="noreferrer" target="_blank">http://www.impredicative.com/c<wbr>gi-bin/mailman/listinfo/ur</a><br>
<br></blockquote></div><br></div></div>
<br>______________________________<wbr>_________________<br>
Ur mailing list<br>
<a href="mailto:Ur@impredicative.com">Ur@impredicative.com</a><br>
<a href="http://www.impredicative.com/cgi-bin/mailman/listinfo/ur" rel="noreferrer" target="_blank">http://www.impredicative.com/<wbr>cgi-bin/mailman/listinfo/ur</a><br>
<br></blockquote></div><br></div>