Boost logo

Boost :

From: Jeff Garland (jeff_at_[hidden])
Date: 2005-01-11 22:15:31


On Tue, 11 Jan 2005 07:51:26 +0000 (UTC), Martin wrote
> I understand what you are saying but the comments in this thread
> (except the discussion Daniel and I have about money implementation)
> seem to be that there is no need for a decimal type in boost unless
> it is compatible with the upcoming standard. Since my solution (and
> your library roadmap) is fixed precision and the standard will be
> floating point (+fixed via encoding) it is not possible.
> (And as I said in another post I don't actually see the need for
> decimal floating point. It solves a couple of theoretical cases
> where you can use == to compare values but are there any real
> applications for it?)

Every application that requires calculations with monetary values -- I
honestly don't know how anyone that implements with the current floating point
types -- the error is totally unpredictable. Just plain not acceptable in the
financial domain. So you either roll your own, buy it from Roque Wave, go
with JAVA, or get your name in the newspaper when the app causes a
multi-million dollar accounting error :-0
 
> Money and currency isn't mentioned on your library roadmap and there
> are no comments here (except from Daniel and he already got a well
> proven money/currency class that he will make available to boost).

You must have missed it -- under ValueTypes there is the 'currency' library
(top left -- middle of diagram). The only thing described in the bullets is
the categories. We explicitly dicussed currency at OOPSLA. A few people
mentioned having a need for it at one point or another.

> Maybe I should concentrate on my locale library instead and add the
> missing locale_cast functions (e.g. locale::to_string(mydouble,
> number_format
> (',','.','3"))

I, for one, would be sorry to see that. Between you and Daniel seems like we
have the potential to get a very valuable library (or 2).

Jeff


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