Stefan Krah <ste...@bytereef.org> added the comment: > I'm also assuming that Decimal(0) sets both base and exponent to 0.
No, 0 is really special in the IBM specification. The magnitude is kept, the precision is not. >>> Decimal("0e10") * Decimal("0e20") Decimal('0E+30') >>> Decimal("0.000e10") Decimal('0E+7') So we're basically doing the reverse of the above in formatting when a precision is given. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue31684> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com