Boost logo

Boost :

From: David Abrahams (dave_at_[hidden])
Date: 2003-09-03 14:10:13


"Jeff Garland" <jeff_at_[hidden]> writes:

>>Jeff G wrote:
>> I'm thinking it would have to be defined like this
>> Duration / Duration --> Integer
>>
>>I think Duration / Duration --> double would be more appropriate.
>
> I have intentionally avoided floating point types in the library
> because there is no reason to suffer the loss of correctness
> associated with these types.

Huh?

     3/2 == 1

is correct?

You get a much bigger round-off error from ints than from floats.

-- 
Dave Abrahams
Boost Consulting
www.boost-consulting.com

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk