Boost logo

Boost :

From: Bill Seymour (bill-at-the-office_at_[hidden])
Date: 2003-07-17 08:02:30


Ilya,

1. You want the scale to be a template parameter so that it's part
    of the type. I've just raised this issue again; and I expect
    there to be some discussion about it. Stay tuned. 8-)

2. You also want the rounding mode to be part of the type. That
    binds the rounding mode to the operand instead of to the
    operator; but I've already chosen the latter. We could reopen
    that discussion if you want to; but I haven't gotten any other
    complaints.

3. You want the internal representation to be a single 64-bit
    integer to make the object smaller. Why?

    For efficiency? Do you think it would be faster to calculate
    the representation of unity for each operation?

    For decreased memory usage? Are you doing embedded systems work?

    Somebody said, "Premature optimization is the root of all evil."
    I can't remember who that was (Knuth? Djikstra?); but somebody
    else on the list will probably tell us.

4. I haven't looked at your example code in detail yet; but at first
    glance, it looks like you're confusing the precision (the maximum
    number of representable digits) with the scale (the number of
    digits to the right of the decimal point).

--Bill Seymour


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