Comparing Fractions

sqrmax at sqrmax at
Mon Mar 23 21:43:31 UTC 1998


Fraction implements #<, but not #>. This results in super > and so... for 
instance, what should take 15ms took about 2 minutes! Not funny at all! Check 
implementing #> like, for instance, this:

#> aNumber
	^(self < aNumber or: [self = aNumber]) not

The methods on #< and #= will take care of adapting and so.


More information about the Squeak-dev mailing list