Mark Dickinson dicki...@gmail.com added the comment:
IMO, the behaviour is fine; it's the docs that are unclear. The rules for
Decimal are different mainly because trailing zeros have meaning for the
Decimal type. (Decimal('1.250') and Decimal('1.25') are two distinct Decimal
objects,
Mark Dickinson dicki...@gmail.com added the comment:
Ah no, I take it back. I think (2) is fine---this is the usual preservation of
trailing zeros where possible. (1) needs to be fixed (and issue #7094 was left
open waiting for this fix).
--
___
Changes by Eric V. Smith e...@trueblade.com:
--
resolution: - duplicate
status: open - closed
superseder: - Add alternate float formatting styles to new-style formatting.
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13838
New submission from py.user port...@yandex.ru:
http://docs.python.org/py3k/library/string.html#format-specification-mini-language
The '#' option:
For floats, complex and Decimal the alternate form causes the result of the
conversion to always contain a decimal-point character, even if no
Eric V. Smith e...@trueblade.com added the comment:
See issue #7098 for a discussion.
I propose to close this issue.
--
nosy: +eric.smith, mark, skrah
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13838
Changes by Eric V. Smith e...@trueblade.com:
--
nosy: +mark.dickinson -mark
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13838
___
___
py.user port...@yandex.ru added the comment:
my question is about the # option
it is described as working with Decimal but it doesn't work with Decimal
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13838