who ever performed bit logic on large negative integer?
nicolas cellier
ncellier at ifrance.com
Sat Jan 26 03:12:28 UTC 2008
SmallInteger < 0 are stored directly in two complement native format
(well, except the tag bits)
But LargeNegativeInteger are stored same as their absolute value.
This does simplify some algorithms. But this leads to quite tricky ones
when bit logic is to be performed based on two complement.
And whenever tricks are used, bugs frequency generally tends to
increase. I believe long life bugs are lying in such swamps.
That's why i'm very proud of finding accidentaly
http://bugs.squeak.org/view.php?id=6874 via
http://bugs.squeak.org/view.php?id=6873.
As usual, most of you won't ever care of it.
Yeah, one more useless bugfix i am specialized in since the probability
you bump into it must not exceed 1.0e-8 per hour of Smalltalking.
But who knows, it's a kind of insurance in case a silly engineer had the
idea to run nearest nuclear plant in Squeak!
And well, it's also for the beauty of mathematics!
Nicolas
More information about the Squeak-dev
mailing list
|