Hi Eliot. I am not sure if you are interested in completly support SmallInteger as methods. If not, please let me know and I don&#39;t bather again.<br><br>I was trying them in Cog, and I have a crash in primitiveFlushCacheByMethod()  when it calls primitiveIndexOf:<br>
because <br><br>primitiveIndexOf: methodPointer<br>    &quot;Note: We now have 10 bits of primitive index, but they are in two places<br>    for temporary backward compatibility.  The time to unpack is negligible,<br>     since the derived primitive function pointer is stored in the method cache.&quot;<br>
    &lt;api&gt;<br>    | primBits |<br>    primBits := ((self headerOf: methodPointer) &gt;&gt; 1) bitAnd: 16r100001FF.<br>    ^(primBits bitAnd: 16r1FF) + (primBits &gt;&gt; 19)<br><br><br><br>But.....&quot;methodPointer&quot; can be a Smallnteger...so headerOf: fails, because rawHeaderOf: fails because it does a &quot;objectMemory fetchPointer: HeaderIndex ofObject: methodPointer&quot;<br>
which send ObjectMemory &gt;&gt; fetchPointer: fieldIndex ofObject: oop<br>which does the final  &quot;self longAt: oop + BaseHeaderSize + (fieldIndex &lt;&lt; ShiftForWord)&quot;<br><br>ok, you got it ;)<br><br>Now....do you consider this a bug?  how could I fix it ?<br>
<br>Thanks<br><br>Mariano<br>