Using mpq_t for aggregating currencies with wildly varying ranges

Donovan Hide donovanhide at
Wed Apr 16 22:22:47 UTC 2014

I've had a lot of success with this project and am very grateful for
everyone's help. One strange bug I've encountered is a difference in output
from this line which deals with values less than one:


on OS X with gmp 6.0.0a I get the expected zero padding:


but on ubuntu saucy with libgmp-dev 2:5.1.2+dfsg-2ubuntu1 the variable
length zero padding doesn't appear:

0.                          17

and I get whitespace instead. Does this sounds like a gmp bug, or am I
getting messed up with compiler versions or flags?


More information about the gmp-discuss mailing list