equal
deleted
inserted
replaced
797 ^ 0 |
797 ^ 0 |
798 |
798 |
799 "Modified: 18.7.1996 / 12:26:38 / cg" |
799 "Modified: 18.7.1996 / 12:26:38 / cg" |
800 ! ! |
800 ! ! |
801 |
801 |
|
802 |
802 !Integer class methodsFor:'prime numbers'! |
803 !Integer class methodsFor:'prime numbers'! |
803 |
804 |
804 flushPrimeCache |
805 flushPrimeCache |
805 "cleanup after using a primeCache. |
806 "cleanup after using a primeCache. |
806 See comment in initializePrimeCacheUpTo:limit" |
807 See comment in initializePrimeCacheUpTo:limit" |
1172 Abstract subclasses must redefine this again." |
1173 Abstract subclasses must redefine this again." |
1173 |
1174 |
1174 ^ self == Integer |
1175 ^ self == Integer |
1175 ! ! |
1176 ! ! |
1176 |
1177 |
|
1178 |
1177 !Integer methodsFor:'Compatibility-Dolphin'! |
1179 !Integer methodsFor:'Compatibility-Dolphin'! |
1178 |
1180 |
1179 & aNumber |
1181 & aNumber |
1180 "return the bitwise-and of the receiver and the argument, anInteger. |
1182 "return the bitwise-and of the receiver and the argument, anInteger. |
1181 Same as bitAnd: - added for compatibility with Dolphin Smalltalk. |
1183 Same as bitAnd: - added for compatibility with Dolphin Smalltalk. |
1435 " |
1437 " |
1436 1 >> -5 |
1438 1 >> -5 |
1437 64 >> 5 |
1439 64 >> 5 |
1438 " |
1440 " |
1439 ! ! |
1441 ! ! |
|
1442 |
1440 |
1443 |
1441 |
1444 |
1442 !Integer methodsFor:'bcd conversion'! |
1445 !Integer methodsFor:'bcd conversion'! |
1443 |
1446 |
1444 decodeFromBCD |
1447 decodeFromBCD |
2733 !Integer methodsFor:'comparing'! |
2736 !Integer methodsFor:'comparing'! |
2734 |
2737 |
2735 hash |
2738 hash |
2736 "redefined to return smallInteger hashValues" |
2739 "redefined to return smallInteger hashValues" |
2737 |
2740 |
2738 ^ self bitAnd:16r3FFFFFFF. |
2741 ^ self bitAnd:SmallInteger maxVal. |
2739 |
2742 |
2740 " |
2743 " |
2741 -20000000000000 hash |
2744 -20000000000000 hash |
2742 20000000000000 hash |
2745 20000000000000 hash |
2743 " |
2746 " |
4849 " |
4852 " |
4850 |
4853 |
4851 "Created: / 09-01-2012 / 17:18:06 / cg" |
4854 "Created: / 09-01-2012 / 17:18:06 / cg" |
4852 ! ! |
4855 ! ! |
4853 |
4856 |
|
4857 |
4854 !Integer methodsFor:'special modulo arithmetic'! |
4858 !Integer methodsFor:'special modulo arithmetic'! |
4855 |
4859 |
4856 add_32:anInteger |
4860 add_32:anInteger |
4857 "return a C-semantic 32bit sum of the receiver and the argument. |
4861 "return a C-semantic 32bit sum of the receiver and the argument. |
4858 Both must be either Small- or LargeIntegers. |
4862 Both must be either Small- or LargeIntegers. |