[Python-checkins] bpo-32720: Fixed the definition for width and precision in format mini-language doc (GH-5482) (GH-5525)

Mariatta webhook-mailer at python.org
Sun Feb 4 01:26:20 EST 2018


https://github.com/python/cpython/commit/3bd749b2122c17b835dc438cdaef63bfdfd61344
commit: 3bd749b2122c17b835dc438cdaef63bfdfd61344
branch: 3.6
author: Miss Islington (bot) <31488909+miss-islington at users.noreply.github.com>
committer: Mariatta <Mariatta at users.noreply.github.com>
date: 2018-02-04T01:26:16-05:00
summary:

bpo-32720: Fixed the definition for width and precision in format mini-language doc (GH-5482) (GH-5525)

Changed the definition of width and precision from "integer" to "digit+" in format mini-language doc.
(cherry picked from commit 8b5fa289fdb04b6b919cf95fa99246aa872e47a8)

Co-authored-by: nathankerr96 <nathankerr96 at gmail.com>

files:
M Doc/library/string.rst

diff --git a/Doc/library/string.rst b/Doc/library/string.rst
index 7a9fcc38bbde..dbafb48a8054 100644
--- a/Doc/library/string.rst
+++ b/Doc/library/string.rst
@@ -304,9 +304,9 @@ The general form of a *standard format specifier* is:
    fill: <any character>
    align: "<" | ">" | "=" | "^"
    sign: "+" | "-" | " "
-   width: `integer`
+   width: `digit`+
    grouping_option: "_" | ","
-   precision: `integer`
+   precision: `digit`+
    type: "b" | "c" | "d" | "e" | "E" | "f" | "F" | "g" | "G" | "n" | "o" | "s" | "x" | "X" | "%"
 
 If a valid *align* value is specified, it can be preceded by a *fill*



More information about the Python-checkins mailing list