From: Bill Seymour (bill-at-the-office_at_[hidden])
Date: 2001-10-04 14:24:30
- WEB wrote:
> Finally, I am disappointed that no one has stepped forward
> to help address the oft-repeated request/need for a general-
> purpose Currency library.
and Kevin Lynch replied:
> I think that this is because many of us see this as a trivial
> extension of a (currently nonexistent) extensible, general
> purpose unit framework, ...
I don't think it would be trivial at all.
In connection with the fixed-point decimal library that I'm
still working on, I did a little research trying to find out
what accountants mean by rounding "up" (I think they mean
away from zero); and I came across a European standard
for converting between euros and EU national currencies.
The requirement are very specific: multiply by the
conversion factor (don't divide by its reciprocal),
figure the answer to six decimal places, then round up.
I wouldn't be surprised to find that there are other
requirements for converting between other currencies
that I don't know about. Coding all those rules into
a single library would seem to be a daunting task.
Also, the conversion factors, in general, aren't
constants; indeed, they can vary from one minute
to the next.
I'd like to work on such a conversion library; but I
need to get the fixed-point decimal proposal finished
first. My current goal is to upload at least the HTML
documentation, and maybe some poorly tested source code,
by the middle of next week, and then be burned by the
flames in person in Redmond. 8-) (I'll be at both the
C and C++ meetings, and I probably won't have e-mail
for the first week.)
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk