digitalmars.D - Status of Decimal Floating Point Module
- Paul D. Anderson (32/32) Oct 30 2012 There have been a couple of me...
There have been a couple of mentions of the decimal module lately so I thought I'd bring everyone up to speed. The short version is that it's probably at an alpha stage of development. If anyone wants to download it and try it out I'd appreciate the feedback. See below. The software is an implementation of the General Decimal Arithmetic Specification (http://speleotrove.com/decimal/decarith.pdf) Current Status: Support for 4 different decimal types: 1) decimal32 2) decimal64 3) decimal128 4) "big" decimal -- arbitrary precision, but user must specify max coefficient and max exponent. Support for all rounding modes called out in the specification. Support for all arithmetic operations called out in the specification. Notes: I just finished implementing the decimal128 type. This was the last major hurdle. (It required an integer128 type so if you're interested that is also available, but only an unsigned version is working.) The remaining work is cleanup, improving tests, improving docs, working through the "TODO"s, improving the exp, log and power functions, and implementing trig functions (which is a good test of basic arithmetic). Feel free to download it from https://github.com/andersonpd/decimal and try it out. I'll be happy to discuss the design, implementation, or anything else about it either here in this forum or offline by e-mail. Paul
Oct 30 2012