digitalmars.D - Decimal Arithmetic
- Paul D. Anderson (7/7) May 23 2011 I've got a D programming language implementation of the General Decimal ...
- Don (2/15) May 24 2011
- filgood (2/32) May 24 2011 Go
- Jesse Phillips (2/6) May 24 2011 D, Definitely.
- Andrej Mitrovic (1/1) May 24 2011 Dial D for D Decimal Arithmetic.
- Paul D. Anderson (3/9) May 24 2011 All right. Seems pretty clear it can be useful. Give me a couple of days...
I've got a D programming language implementation of the General Decimal Arithmetic specification (http://speleotrove.com/decimal/) that's' more or less complete* and am wondering if it would be useful. I worked on this over a year ago but life got in the way, so I neglected it for a time. I now have the time to finish it. It uses std.bigint as the basis for the decimal numbers. I know there are plans to bring BigFloat, decimal32, decimal64, and decimal128 numbers into D. The completed* portion of the code fills the role of BigFloat (although I called it Decimal), and I've got routines that encode/decode the dec32, etc. numbers but they're not as far along as the arbitrary precision version. I guess my question is whether I'm repeating work that's been done or is being done in this area? If so, maybe I can lend a hand. If not, I'd like some feedback on what is needed so I can work on the important things first. Let me know what you think. At this point I'd settle for a go/nogo decision. We can work bikeshed stuff later. Thanks, Paul *"more or less complete" == It passes all the tests built in to the spec. No logical operators or exp/ln/power. Still needs work. I suppose it could be called an alpha version.
May 23 2011
Paul D. Anderson wrote:I've got a D programming language implementation of the General Decimal Arithmetic specification (http://speleotrove.com/decimal/) that's' more or less complete* and am wondering if it would be useful. I worked on this over a year ago but life got in the way, so I neglected it for a time. I now have the time to finish it. It uses std.bigint as the basis for the decimal numbers. I know there are plans to bring BigFloat, decimal32, decimal64, and decimal128 numbers into D. The completed* portion of the code fills the role of BigFloat (although I called it Decimal), and I've got routines that encode/decode the dec32, etc. numbers but they're not as far along as the arbitrary precision version. I guess my question is whether I'm repeating work that's been done or is being done in this area? If so, maybe I can lend a hand. If not, I'd like some feedback on what is needed so I can work on the important things first. Let me know what you think. At this point I'd settle for a go/nogo decision. We can work bikeshed stuff later.Go! We definitely want to get this into Phobos.Thanks, Paul *"more or less complete" == It passes all the tests built in to the spec. No logical operators or exp/ln/power. Still needs work. I suppose it could be called an alpha version.
May 24 2011
On 24/05/2011 08:34, Don wrote:Paul D. Anderson wrote:GoI've got a D programming language implementation of the General Decimal Arithmetic specification (http://speleotrove.com/decimal/) that's' more or less complete* and am wondering if it would be useful. I worked on this over a year ago but life got in the way, so I neglected it for a time. I now have the time to finish it. It uses std.bigint as the basis for the decimal numbers. I know there are plans to bring BigFloat, decimal32, decimal64, and decimal128 numbers into D. The completed* portion of the code fills the role of BigFloat (although I called it Decimal), and I've got routines that encode/decode the dec32, etc. numbers but they're not as far along as the arbitrary precision version. I guess my question is whether I'm repeating work that's been done or is being done in this area? If so, maybe I can lend a hand. If not, I'd like some feedback on what is needed so I can work on the important things first. Let me know what you think. At this point I'd settle for a go/nogo decision. We can work bikeshed stuff later.Go! We definitely want to get this into Phobos.Thanks, Paul *"more or less complete" == It passes all the tests built in to the spec. No logical operators or exp/ln/power. Still needs work. I suppose it could be called an alpha version.
May 24 2011
filgood Wrote:On 24/05/2011 08:34, Don wrote:D, Definitely.Go! We definitely want to get this into Phobos.Go
May 24 2011
Paul D. Anderson Wrote:Let me know what you think. At this point I'd settle for a go/nogo decision. We can work bikeshed stuff later. Thanks, PaulAll right. Seems pretty clear it can be useful. Give me a couple of days to tidy up the code and I'll post it. Thanks.
May 24 2011