import std.stdio; auto a = Decimal!1("777.7"); auto b = Decimal!1("777"); import mir.format; assert(stringBuf() << cast(double)a - cast(double)b << getData == "0.7000000000000455"); a -= b; assert(stringBuf() << a << getData == "0.7"); a = Decimal!1("-777.7"); b = Decimal!1("777"); a += b; assert(stringBuf() << a << getData == "-0.7"); a = Decimal!1("777.7"); b = Decimal!1("-777"); a += b; assert(stringBuf() << a << getData == "0.7"); a = Decimal!1("777"); b = Decimal!1("777.7"); a -= b; assert(stringBuf() << a << getData == "-0.7");