<div dir="ltr"><div dir="ltr"><div class="gmail_default" style="font-size:small"><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Dec 28, 2021 at 4:56 PM Eliot Miranda <<a href="mailto:eliot.miranda@gmail.com">eliot.miranda@gmail.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 dir="ltr"><div style="font-size:small">Christoph,</div><div style="font-size:small"><br></div><div style="font-size:small">    you can't just add such primitives and assume they'll work.   You need to at least discuss with me up front and/or read the VMMaker implementations. Spur primitive dispatch depends on the receiver having been sent a message and hence unforwarded.  When you use a primitive where the effective receiver is an argument that guarantee no longer holds.  Such usage needs primitives rewriting.  And eventually performance gains from the architecture will be eroded.</div></div></blockquote><div><br></div><div class="gmail_default" style="font-size:small">The set of mirror primitives has been chosen to support execution simulation.  You're n ow making assumptions and changes to that, without discussion.  I am dismayed.  I argued for you becoming a core developer and now what I see seems rather intemperate and ill-considered.</div><div class="gmail_default" style="font-size:small"><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"><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Dec 28, 2021 at 4:47 PM <<a href="mailto:commits@source.squeak.org" target="_blank">commits@source.squeak.org</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">Christoph Thiede uploaded a new version of Kernel to project The Trunk:<br>
<a href="http://source.squeak.org/trunk/Kernel-ct.1439.mcz" rel="noreferrer" target="_blank">http://source.squeak.org/trunk/Kernel-ct.1439.mcz</a><br>
<br>
==================== Summary ====================<br>
<br>
Name: Kernel-ct.1439<br>
Author: ct<br>
Time: 29 December 2021, 1:47:06.285067 am<br>
UUID: f55ab880-48e4-7946-b734-58afc7d03b57<br>
Ancestors: Kernel-ct.1438, Kernel-ct.1404<br>
<br>
Adds mirror primitives for primitiveGetImmutability (primitive 163/#isReadOnlyObject), primitiveSetImmutability (primitive 164/#setIsReadOnlyObject:), and primitiveClone (primitive 148/#shallowCopy).<br>
<br>
=============== Diff against Kernel-ct.1438 ===============<br>
<br>
Item was added:<br>
+ ----- Method: Context>>object:setIsReadOnly: (in category 'mirror primitives') -----<br>
+ object: anObject setIsReadOnly: aBoolean<br>
+       "Set the read-only flag of the argument anObject to the given value aBoolean and answer the previous value of the flag, without sending a message to anObject. This mimics the action of the VM when an object is set as read-only or writeable. See Object >> #setIsReadOnlyObject:."<br>
+ <br>
+       <primitive: 164 error: ec><br>
+       self primitiveFailed!<br>
<br>
Item was added:<br>
+ ----- Method: Context>>objectClone: (in category 'mirror primitives') -----<br>
+ objectClone: anObject<br>
+       "Answer a copy the argument anObject which share's the original's instance variables, without sending it a message. This mimics the action of the VM when it clones an object.<br>
+        Used to simulate the execution machinery by, for example, the debugger.<br>
+        Primitive.  See Object documentation whatIsAPrimitive."<br>
+ <br>
+       <primitive: 148><br>
+       self primitiveFailed!<br>
<br>
Item was added:<br>
+ ----- Method: Context>>objectIsReadOnly: (in category 'mirror primitives') -----<br>
+ objectIsReadOnly: anObject<br>
+       "Answer if the argument is read-only without sending it a message. This mimics the action of the VM when an object is tested for writeability. See Object >> #isReadOnlyObject."<br>
+ <br>
+       <primitive: 163 error: ec><br>
+       ^ (self objectClass: anObject) isImmediateClass!<br>
<br>
<br>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr"><div dir="ltr"><div><span style="font-size:small;border-collapse:separate"><div>_,,,^..^,,,_<br></div><div>best, Eliot</div></span></div></div></div>
</blockquote></div><br clear="all"><div><br></div>-- <br><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>