Bugs: Browse | Submit New | Admin
Seems like the BigDecimal intialisation code has a bug: This positive value is interpretted as I'd expect: >> BigDecimal.new(".31").to_s => "0.31" But this negative one isn't: >> BigDecimal.new("-.31").to_s => "0.31" Cheers, Mark
Add A Comment:
Date: 2007-03-24 19:08 Sender: Benjamin Atkin If you have a leading zero, it works: irb(main):005:0> BigDecimal.new("-0.31").to_s => "-0.31E0"