[issue17072] Decimal, quantize, round and negative value

2013-02-10 Thread Hakim Taklanti
Hakim Taklanti added the comment: You is right. I had just see the beginning of documentation ("Rounding options include..."). Sorry for the bother and thanks for the answer. -- ___ Python tracker <http://bugs.python.o

[issue17072] Decimal, quantize, round and negative value

2013-01-29 Thread Hakim Taklanti
Hakim Taklanti added the comment: Indeed, perhaps to enhance the documentation. Thanks. -- ___ Python tracker <http://bugs.python.org/issue17072> ___ ___ Pytho

[issue17072] Decimal, quantize, round and negative value

2013-01-29 Thread Hakim Taklanti
New submission from Hakim Taklanti: >>> from decimal import Decimal >>> from decimal import ROUND_UP, ROUND_DOWN >>> a = Decimal("-3.86") >>> b = Decimal("5.73") >>> a_up = a.quantize(Decimal(".1"), ROUND_UP) >>>