Skip to content

Commit a32e584

Browse files
authored
Rollup merge of rust-lang#72452 - Lucretiel:precision-doc, r=dtolnay
Clarified the documentation for Formatter::precision Added a note that `precision` is interpreted as max-width when formatting strings
2 parents 7caf5fb + 526dbd3 commit a32e584

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/libcore/fmt/mod.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -1618,7 +1618,8 @@ impl<'a> Formatter<'a> {
16181618
self.width
16191619
}
16201620

1621-
/// Optionally specified precision for numeric types.
1621+
/// Optionally specified precision for numeric types. Alternatively, the
1622+
/// maximum width for string types.
16221623
///
16231624
/// # Examples
16241625
///

0 commit comments

Comments
 (0)