<meta charset="utf-8"><div class="gmail_quote"><br class="Apple-interchange-newline">On Thu, Jul 22, 2010 at 4:58 AM, Robby Findler <span dir="ltr">&lt;<a href="mailto:robby@eecs.northwestern.edu">robby@eecs.northwestern.edu</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0.8ex; border-left-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; padding-left: 1ex; ">
 </blockquote><blockquote class="gmail_quote" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0.8ex; border-left-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; padding-left: 1ex; ">
The way the contract system creates the wrappers is a bit subtle. In<br>general, it needs to create at least one wrapper object per module<br>that uses the procedure so it tries to create at most one as well, but<br>in the REPL it cannot do that, so it creates one wrapper per use of<br>
the variable. (The reason it needs at least one per module that uses<br>the procedure is for proper blame assignment. If two modules, say A<br>and B, both use the contracted function, then either module might be<br>blamed, so one wrapper function has an &quot;A&quot; somewhere inside the other<br>
has a &quot;B&quot;.)<br><br></blockquote></div><div><br></div><div>Ah I see why they do not eq each other now.  This is indeed quite subtle.  My thought has always been that the exported contract function in module A is the same exported contract function in module B, and they magically know where they are being invoked, instead of having two separate wrappers. </div>
<div><br></div><div>Thanks for the explanation Robby.  I will see what I can do with this.  </div><div><br></div><div>Cheers,</div><div>yc</div><div><br></div>