[Pkg] The Trunk: Kernel-nice.616.mcz

commits at source.squeak.org commits at source.squeak.org
Wed Sep 7 20:08:31 UTC 2011


Nicolas Cellier uploaded a new version of Kernel to project The Trunk:
http://source.squeak.org/trunk/Kernel-nice.616.mcz

==================== Summary ====================

Name: Kernel-nice.616
Author: nice
Time: 7 September 2011, 10:07:42.842 pm
UUID: 7aedbc4c-8362-48cb-bfbe-7b28ef66837c
Ancestors: Kernel-nice.615

Form a Fraction explicitely rather than sending asFraction when coercing an Integer is required.
This way, Integer>>#isFraction and Integer>>#asFraction can be modified.

=============== Diff against Kernel-nice.615 ===============

Item was changed:
  ----- Method: Fraction>>adaptToInteger:andSend: (in category 'converting') -----
  adaptToInteger: rcvr andSend: selector
  	"If I am involved in arithmetic with an Integer, convert it to a Fraction."
+ 	^ (Fraction numerator: rcvr denominator: 1) perform: selector with: self!
- 	^ rcvr asFraction perform: selector with: self!

Item was changed:
  ----- Method: Integer>>adaptToFraction:andSend: (in category 'converting') -----
  adaptToFraction: rcvr andSend: selector
  	"If I am involved in arithmetic with a Fraction, convert me to a Fraction."
+ 	^ rcvr perform: selector with: (Fraction numerator: self denominator: 1)!
- 	^ rcvr perform: selector with: self asFraction!



More information about the Packages mailing list