<div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Mar 11, 2013 at 4:39 PM, Frank Shearar <span dir="ltr"><<a href="mailto:frank.shearar@gmail.com" target="_blank">frank.shearar@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">And _that_ would be because the latest version of Environments does<br>
funky stuff with class resolution. Yes?<br></blockquote><div><br></div><div>Yes. There are actually two bugs here:</div><div><br></div><div>The first is that Environment>>at:put: doesn't pull existing bindings out of Undeclared. Here's what happens: the Doit in <a href="http://prepare-test-image.st">prepare-test-image.st</a> looks basically like this:</div>
<div><br></div></div></div><blockquote class="webkit-indent-blockquote" style="margin:0 0 0 40px;border:none;padding:0px"><div class="gmail_extra"><div class="gmail_quote"><div><font class="Apple-style-span" face="'times new roman', serif">Smalltalk at: #Log put: [:arg].</font></div>
</div></div><div class="gmail_extra"><div class="gmail_quote"><div><font class="Apple-style-span" face="'times new roman', serif">Log value: 'test'. </font></div></div></div></blockquote><div class="gmail_extra">
<div class="gmail_quote"><div><br></div><div>When this code is compiled, the reference to Log on line 2 is undeclared. Then execution starts, and line 1 does an assignment to Log though sneaky reflection, rather than assignment. SystemDictionary overrides #at:put: to make sure this works, but Environments doesn't, so the binding on line 2 isn't affected. Then we execute line 2, and send #value: to nil, which raises a MNU. </div>
<div><br></div><div>We get a debugger, click on the DoIt frame to see what happened, and boom, a syntax error. The DoIt doesn't have a source pointer, because the code is in a .st file, so we need to decompile it. The new binding classes in Environments don't support decompilation well, so it produces invalid source. I'm not sure why we're reparsing decompiled code, but clearly it's not working.</div>
<div><br></div><div>I should be able to just commit fixes to the trunk, since this doesn't break updating, just building the test image. </div><div><br></div><div>Colin</div></div></div></div>