equal
deleted
inserted
replaced
1040 |
1040 |
1041 %{ /* NOCONTEXT */ |
1041 %{ /* NOCONTEXT */ |
1042 |
1042 |
1043 /* and all bits except tag */ |
1043 /* and all bits except tag */ |
1044 if (__isSmallInteger(aMask)) { |
1044 if (__isSmallInteger(aMask)) { |
1045 RETURN ( ((INT)self & ((INT)aMask & ~TAG_MASK)) ? true : false ); |
1045 RETURN ( ((INT)self & ((INT)aMask & ~TAG_MASK)) ? true : false ); |
1046 } |
1046 } |
1047 %}. |
1047 %}. |
1048 aMask class == LargeInteger ifTrue:[ |
1048 aMask class == LargeInteger ifTrue:[ |
1049 ^ (aMask bitAnd:self) ~~ 0 |
1049 ^ (aMask bitAnd:self) ~~ 0 |
1050 ]. |
1050 ]. |
1051 ^ self retry:#bitTest: coercing:aMask |
1051 ^ self retry:#bitTest: coercing:aMask |
|
1052 |
|
1053 " |
|
1054 2r10001 bitTest:2r00001 |
|
1055 2r10001 bitTest:2r00010 |
|
1056 2r10001 bitTest:2r00100 |
|
1057 2r10001 bitTest:2r01000 |
|
1058 2r10001 bitTest:2r10000 |
|
1059 2r10001 bitTest:2r10001 |
|
1060 2r10001 bitTest:2r10010 |
|
1061 " |
1052 ! |
1062 ! |
1053 |
1063 |
1054 bitXor:anInteger |
1064 bitXor:anInteger |
1055 "return the bitwise-exclusive-or of the receiver and the argument, anInteger" |
1065 "return the bitwise-exclusive-or of the receiver and the argument, anInteger" |
1056 |
1066 |
3796 ! ! |
3806 ! ! |
3797 |
3807 |
3798 !SmallInteger class methodsFor:'documentation'! |
3808 !SmallInteger class methodsFor:'documentation'! |
3799 |
3809 |
3800 version |
3810 version |
3801 ^ '$Header: /cvs/stx/stx/libbasic/SmallInteger.st,v 1.174 2009-02-01 11:05:51 cg Exp $' |
3811 ^ '$Header: /cvs/stx/stx/libbasic/SmallInteger.st,v 1.175 2009-02-06 14:07:32 cg Exp $' |
3802 ! ! |
3812 ! ! |