## PackageDescription: SYSBUG-FloatComparison

SYSBUG - Float ComparisonLast published: March 3, 2021 by 'nice'

Defines 0 Classes

Extends 7 Classes

This is a patch against following Equality transitivity problems

| a b c |

a := 16r1FFFFFFFFFFFFF0.

b := a asDouble.

c := a + 1.

(a = b) & (b = c) ifTrue: [self assert: (a = c)]

"note: this is squeak imply operator

self assert: (a = b) & (b = c) ==> (a = c)"

| a b c |

a := 16r1FFFFFFFFFFFFF0.

b := a asDouble.

c := a + 1.

(a = b) & (a < c) ifTrue: [self assert: (b < c)]

"note: this is squeak imply operator

self assert: (a = b) & (a < c) ==> (b < c)"

Current implementation (in VW/Squeak/Dolphin/STX/gst etc...) is incorrectly coercing to Double in order to perform comparisons.

I claim on the contrary that it should convert double asFraction in order to perform comparison.

These bugs have various consequences on Sets (size might depend on order which elements are added)

And it is scratching formal beauty of my favourite language.

Please include it in your image.

From nicolas cellier