[issue22546] Wrong default precision in documentation for format

2014-10-05 Thread Terry J. Reedy
Terry J. Reedy added the comment: Tommy, thanks for reporting this. -- resolution: -> fixed stage: needs patch -> resolved status: open -> closed ___ Python tracker ___

[issue22546] Wrong default precision in documentation for format

2014-10-05 Thread Roundup Robot
Roundup Robot added the comment: New changeset 041d0752171a by Terry Jan Reedy in branch '3.4': Issue #22546: update doc for mini-language float None presentation type. https://hg.python.org/cpython/rev/041d0752171a -- nosy: +python-dev ___ Python tra

[issue22546] Wrong default precision in documentation for format

2014-10-05 Thread Mark Dickinson
Mark Dickinson added the comment: Terry: your rewrite looks fine to me. +1 for committing that. -- ___ Python tracker ___ ___ Python-

[issue22546] Wrong default precision in documentation for format

2014-10-04 Thread Terry J. Reedy
Terry J. Reedy added the comment: I see now that my expectation, based on decimal rounding rather than binary conversion and rounding, was wrong ;-) >>> 33.14159265358979323846264338327950288419 == 33.1415926535898 True >>> 33.14159265358979323846264338327950288419 == 33.14159265358979 False >>>

[issue22546] Wrong default precision in documentation for format

2014-10-04 Thread Mark Dickinson
Mark Dickinson added the comment: Hmm; it's only outputs in non-scientific notation that are guaranteed to have a decimal point. Patch updated. -- Added file: http://bugs.python.org/file36799/missing_type_specifier2.patch ___ Python tracker

[issue22546] Wrong default precision in documentation for format

2014-10-04 Thread Mark Dickinson
Mark Dickinson added the comment: Here's a proposed fix. -- keywords: +patch Added file: http://bugs.python.org/file36798/missing_type_specifier.patch ___ Python tracker ___

[issue22546] Wrong default precision in documentation for format

2014-10-04 Thread Tommy Andersen
Changes by Tommy Andersen : -- versions: +Python 3.3 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://ma

[issue22546] Wrong default precision in documentation for format

2014-10-04 Thread Mark Dickinson
Mark Dickinson added the comment: > It seems that str, repr, and '' are using precision 16 None of them is using a fixed precision: they're all using David Gay's implementation of the "shortest string" algorithm (à la Burger and Dybvig). For repr, this is the case since Python 3.1 / 2.7; for

[issue22546] Wrong default precision in documentation for format

2014-10-03 Thread Terry J. Reedy
Terry J. Reedy added the comment: "The precision is a decimal number indicating how many digits should be displayed ... before and after the decimal point for a floating point value formatted with 'g' or 'G'. It seems that str, repr, and '' are using precision 16, and the doc should be changed

[issue22546] Wrong default precision in documentation for format

2014-10-03 Thread Eric V. Smith
Eric V. Smith added the comment: I think this is a result of changing the precision of str() to match repr(). 2.7 prints: '3.14159265359' -- ___ Python tracker ___ _

[issue22546] Wrong default precision in documentation for format

2014-10-03 Thread Eric V. Smith
Changes by Eric V. Smith : -- nosy: +eric.smith, mark.dickinson ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue22546] Wrong default precision in documentation for format

2014-10-03 Thread Tommy Andersen
New submission from Tommy Andersen: The format documentation for the Format Specification Mini-Language for python 3.3 (perhaps newer and older as well) at: https://docs.python.org/3.3/library/string.html States for type '' (for floating point numbers): Similar to 'g', except with at lea