Oct. 31, 2016
9:49 p.m.
On Oct 31, 2016, at 3:58 PM, Martin McClure <martin@hand2mouse.com> wrote:
(1.19 roundTo: (1/10))asFloat
I should note that the final example *should* result in a Float without having to have #asFloat sent to it. Per ANSI and traditional Smalltalk practice, any operation where the receiver *or* the argument is a Float produces a Float.
While ANSI says that the numbers should be converted using the default conversion table, all of the Smalltalkâs that Iâve tried donât follow that. Iâve tried Dolphin, VW, Pharo, & VAST, and all return fractions. I prefer this behavior over the ANSI behavior. John Brant