<div dir="ltr"><div><div><div><div><div><div><div>I am using Squeak  3.11.  I assume the same results apply to Squeak 4.4.  If not, my apologies.<br><br>In Squeak if I evaluate:<br><br>1)  ((2 &lt;&lt; 256)  bitAnd: (2 &lt;&lt; 128)) ==&gt;  0<br>
2)  ((2 &lt;&lt; 256)  bitAnd: (2 &lt;&lt; 128)) class ==&gt; SmallInteger<br></div>3)  (2 &lt;&lt; 128)                               ==&gt;  680564733841876926926749214863536422912<br></div><div>4)  ((2 &lt;&lt; 128) bitAnd: (2 &lt;&lt; 128))  ==&gt;  680564733841876926926749214863536422912<br>
<br></div>This all looks correct and I care because I need to do &lt;bitAnd:&gt; of some largePositiveIntegers.<br><br></div>But &lt;LargePositiveInteger&gt;&gt;BitAnd:&gt;  is:<br><br></div>&quot;Primitive. Answer an Integer whose bits are the logical AND of the<br>
    receiver&#39;s bits and those of the argument. Fail if the receiver or argument<br>    is greater than 32 bits. See Object documentation whatIsAPrimitive.&quot;<br>    &lt;primitive: 14&gt;<br>    self halt.          &quot;I ADDED THE HALT&quot;<br>
    ^ super bitAnd: anInteger<br></div><br></div>The way I see it  &lt;LargePositiveInteger&gt;&gt;BitAnd:&gt;   is always going to fail and thus invoke its super version<br></div><div>(&lt;LargePositiveInteger&gt;&gt;BitAnd:&gt;)  and this is what I see when I run the code; i.e. I hit the halt.<br>
<br>So why have &lt;LargePositiveInteger&gt;&gt;BitAnd:&gt; method at all?<br><br></div><div>Ditto for the other bit operations.<br><br></div><div>Ralph Boland<br></div></div>