Eric V. Smith <e...@trueblade.com> added the comment:

If you're using round(str(some_float), digits) and the result is a float, then 
that's a problem, since you're going to round it again for display at some 
point.

If you want a string result, you're better off using format(float, 
format_spec), or f-strings, or str.format() (all of which have the same 
underlying implementation) to do your float-to-string-for-display-purposes work.

I just don't see how getting a binary float via decimal rounding would be 
useful.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue41598>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to