-
Notifications
You must be signed in to change notification settings - Fork 13.5k
Fix std::fmt format spec: named args are allowed with "$" syntax #33277
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Conversation
r? @aturon (rust_highfive has picked a reviewer for you, use r? to override) |
@@ -456,6 +456,10 @@ | |||
//! // Hello {next arg (x)} is {arg 2 (0.01) with precision | |||
//! // specified in its predecessor (5)} | |||
//! println!("Hello {} is {2:.*}", "x", 5, 0.01); | |||
//! | |||
//! // Hello {next arg (x)} is {arg "number" (0.01) with precision specified | |||
//! in arg "prec" (5)} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing "//" at the beginning of the line.
Except for the nit, everything's good. Thanks for the PR. Ping me once it's fixed. |
344063c
to
a12344f
Compare
@GuillaumeGomez thanks, fixed. |
@@ -333,7 +333,7 @@ | |||
//! precision := count | '*' | |||
//! type := identifier | '' | |||
//! count := parameter | integer | |||
//! parameter := integer '$' | |||
//! parameter := argument '$' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wouldn't we want this to be integer or argument?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
argument
is defined above as integer | identifier
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah! I missed that 👍
a12344f
to
84bd1ce
Compare
@bors: r+ rollup |
📌 Commit 84bd1ce has been approved by |
🌟 Nice to get this into the docs, then it also gets into rust code out there eventually |
Fix std::fmt format spec: named args are allowed with "$" syntax
💔 Test failed - auto-mac-64-opt-rustbuild |
@bors: retry On Sat, Apr 30, 2016 at 12:59 PM, bors notifications@github.com wrote:
|
💔 Test failed - auto-win-gnu-32-opt-rustbuild |
@bors: retry On Sat, Apr 30, 2016 at 3:02 PM, bors notifications@github.com wrote:
|
💔 Test failed - auto-linux-64-opt-mir |
…=steveklabnik Fix std::fmt format spec: named args are allowed with "$" syntax
…=steveklabnik Fix std::fmt format spec: named args are allowed with "$" syntax
@bors: retry |
No description provided.