-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Make mention of alternate flags in std::fmt traits #26850
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
r? @huonw (rust_highfive has picked a reviewer for you, use r? to override) |
Thanks! One of the most awesome parts of this ist that it works for nested structures, too. Do you maybe want to add a more complex example somewhere? (Feel free to copy my test code!) |
I don't know, I guess I just assume that it would do so, but maybe assumptions don't matter. |
@@ -379,6 +410,8 @@ pub trait Display { | |||
/// | |||
/// The `Octal` trait should format its output as a number in base-8. | |||
/// | |||
/// The alternate flag, `#o`, adds a `0o` in front of the output. |
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.
Hm, isn't just #
the alternate flag not the full #o
entity? (i.e. one adds the flag to the format specifier o
)
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.
I guess technically that is true.
02eb698
to
6c52903
Compare
@huonw updated! |
https://www.reddit.com/r/rust/comments/3ceaui/psa_produces_prettyprinted_debug_output/