Boost logo

Boost :

From: Richard Kaiser (rk_at_[hidden])
Date: 2004-05-20 08:02:37

I want to ask the boost community if there is interest in a decimal
floating-point class implementing one or more of the decimal
floating-point types that are intended to become part of a future C and
C++ standard.

This class would be a wrapper class around Mike Cowlishaws decNumber C
library. You can take a look at my first preliminary version (it is just
a first try, the design is far from perfect, it is incomplete, its
notation is inconsistent and not according to boost conventions) at

Most of its operators work as they should do, and most of Mikes
testcases pass successfully. The function
in my test program test_rk reads all the testcases from Mikes decTest
files and logs each testcase in a file (bcb files were created with
Borland C++Builder 6, gcc with MinGW g++, and msc with MS Visual Studio
.Net). With “grep "###number" *.log” you get the summary lines:

  File abs.decTest_bcb.log: ###number of tests passed=87 failed=2
  File abs.decTest_gcc.log: ###number of tests passed=87 failed=2
  File abs.decTest_msc.log: ###number of tests passed=87 failed=2
  File add.decTest_bcb.log: ###number of tests passed=773 failed=45
  File add.decTest_gcc.log: ###number of tests passed=773 failed=46
  File add.decTest_msc.log: ###number of tests passed=773 failed=45

If the boost community is interested, if I find enough time, and if
everything works as intended, the resulting classes would be a reference
implementation for the new standard decimal floating point types, or at
least a close one.

I posted this request already some days ago, but by mistake I have
posted it as a reply to a message it did not belong to. Sorry.

Richard Kaiser

Boost list run by bdawes at, gregod at, cpdaniel at, john at