Newsgroups: comp.lang.smalltalk
Path: cantaloupe.srv.cs.cmu.edu!das-news2.harvard.edu!news2.near.net!MathWorks.Com!solaris.cc.vt.edu!uunet!s5!is1.is.morgan.com!is.morgan.com!kiisaka
From: kiisaka@is.morgan.com (Ken Iisaka)
Subject: Re: Anything better than Float?
Message-ID: <1994Oct12.125921@is.morgan.com>
Sender: news@is.morgan.com
Nntp-Posting-Host: bkis109
Organization: Or Lack Thereof
References:  <37akc6$4ur$1@melbourne.dialix.oz.au>
Date: Wed, 12 Oct 1994 16:59:21 GMT
Lines: 22

In article <37akc6$4ur$1@melbourne.dialix.oz.au>, btate@melbourne.dialix.oz.au (Bradley Tate)  My hope is that in my ignorance I have overlooked something. Visual Basic,
|> much as I loathe it, gives a currency type which is (10).(4) digits, and
|> C will give me doubles (8 bytes) which is enough for the purpose. Smalltalk,
|> OTOH will give me about 7 digits of accuracy in a 4 byte representation,
|> with rounding errors every time I look around. 
|> 
|> Wots a poor boy to do? Has anybody got a suggestion? I'm almost certainly not
|> the first person to run into this sort of problem.

Use Double.  If you can afford the overhead, use Fixed which will give
you as many as significant digits you want.

-- 
|  ###    ###  |  ###   ###   ###  |  ###    ###  |  ###   ###   ###  |
|  ###    ###  |  ###   ###   ###  |  ###    ###  |  ###   ###   ###  |
|  ###    ###  |  ###   ###   ###  |  ###    ###  |  ###   ###   ###  |
|  ###    ###  |  ###   ###   ###  |  ###    ###  |  ###   ###   ###  |
|    |    |    |    |    |    |    |    |    |    |    |    |    |    |
|  Ken Iisaka  |  (kiisaka@morgan.com)  |  Morgan Stanley & Co. Inc   |
|  1 Pierrepont Plz, Brooklyn, NY 11201 |   All disclaimers apply.    |
|____|____|____|____|____|____|____|____|____|____|____|____|____|____|___
"Smalltalk Goes Object Oriented" - INFORMATIONWEEK, August 8, 1994, pg. 58
