`boost::cnv::printf` uses wrong format for str to double
dvirtz opened this issue · 1 comments
dvirtz commented
The correct sscanf
format for double
is %lf
while current code uses %f
:
convert/include/boost/convert/printf.hpp
Line 75 in 2eec956
This results in wrong value when converting a string to double
:
fmt::print("{}\n", boost::convert<double>("3.14", cnv).value()); // prints 5.32861326e-315
yet-another-user commented
Indeed. Thank you for picking it up. Much appreciated. Fixed in the develop branch. Should make it to the master branch the the next release. Tnx again.