<div dir="ltr"><div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Feb 26, 2019 at 2:06 PM <<a href="mailto:ken.dickey@whidbey.com">ken.dickey@whidbey.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div style="font-size:10pt;font-family:Verdana,Geneva,sans-serif">
<p>On 2019-02-26 13:05, Eliot Miranda wrote:</p>
<blockquote type="cite" style="padding:0px 0.4em;border-left-width:2px;border-left-style:solid;border-left-color:rgb(16,16,255);margin:0px">
<div dir="ltr">
<div dir="ltr">Hi Ken,</div>
<br>
<div class="gmail_quote">
<div class="gmail_attr" dir="ltr">On Tue, Feb 26, 2019 at 11:52 AM <<a href="mailto:ken.dickey@whidbey.com" target="_blank">ken.dickey@whidbey.com</a>> wrote:</div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex">Oh,  I should point out that the CLI prints:<br> <br> The 9 doubles are 1.000000 2.000000 3.000000 4.000000 5.000000 6.000000 <br> 7.000000 8.000000 9.000000<br> <br> when running the FFI unit tests and:<br> <br> The 9 doubles are 1.000000 1.000000 1.000000 4.000000 5.000000 6.000000 <br> 7.000000 8.000000 9.000000</blockquote>
<div> </div>
<div>This looks like the marshaller is accessing the wrong initial arguments.  It looks like the object accessed for args 1 & 2 is the same as for arg 0, right?  The question is why.  I have no clue.</div>
</div>
</div>
</blockquote>
<p>Is there a compiler/runtime/parser change?</p></div></blockquote><div><br></div><div>No.  In the Workspace there is invocation via withArgs:executeMethod:, primitive 188.  But I find it hard to believe this is the issue.  This code is correct and I don't see there can be any issue with it and have as much of tech system work as you do.  In all cases there is only one source to bytecode compiler doing the compiler, best doits, method compilation, image segment load evaluation, etc, etc.</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div style="font-size:10pt;font-family:Verdana,Geneva,sans-serif">
<p>Calling</p>
<p>========================</p>
<p>FFIPluginTests>>testGenericDoubleCall2<br> "Test using generic FFI spec"<br> | result |<br> result := FFITestLibrary ffiTestDoubles9: 1.0 d: 2.0 d: 3.0 d: 4.0 d: 5.0 d: 6.0 d: 7.0 d: 8.0 d: 9.0.<br> self assert: result = 45.0</p>
<p>=========================</p>
<p>works fine, but in a workspace, </p>
<p>FFITestLibrary ffiTestDoubles9: 1.0 d: 2.0 d: 3.0 d: 4.0 d: 5.0 d: 6.0 d: 7.0 d: 8.0 d: 9.0. --> 42.0</p>
<p>=========================</p>
<p>Typed space in <span>FFIPluginTests>>testGenericDoubleCall2, accept (s), and source text now shows:</span></p>
<p><span>============</span></p>
<p><span>FFIPluginTests>>testGenericDoubleCall2<br>"Test using generic FFI spec"<br>| result |<br>result := FFITestLibrary ffiTestDoubles9: 1.0 </span><span>d: 1.0 d: 1.0 d: 4.0 d: 5.0 d: 6.0 d: 7.0 d: 8.0 d: 9.0.<br>self assert: result = 1.0</span></p>
<p><span>===============</span></p>
<p><span>!?!?!WTF!?!?!</span></p></div></blockquote><div><br></div><div>I don't understand.  How can typing a space produce a totally different version of the method?  Have you checked the bytecode in the </div><div><br></div></div><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><span style="font-size:small;border-collapse:separate"><div>_,,,^..^,,,_<br></div><div>best, Eliot</div></span></div></div></div></div></div>