Skip to content
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

Signs in fmt documenation #38677

Closed
cbreeden opened this issue Dec 29, 2016 · 3 comments
Closed

Signs in fmt documenation #38677

cbreeden opened this issue Dec 29, 2016 · 3 comments
Labels
E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.

Comments

@cbreeden
Copy link
Contributor

cf: https://doc.rust-lang.org/std/fmt/index.html#sign0

+ - This is intended for numeric types and indicates that the sign should always be printed. Positive signs are never printed by default, and the negative sign is only printed by default for the Signed trait. This flag indicates that the correct sign (+ or -) should always be printed.

This can't be accurate as there is no Signed trait anymore. Though, it's unclear to me if + is even allowed in formatting, so I don't feel comfortable modifying the docs here.

@cbreeden cbreeden changed the title Signs in formatting documenation Signs in fmt documenation Dec 29, 2016
@brson
Copy link
Contributor

brson commented Dec 29, 2016

Should probably just say "for signed types".

@brson brson added the E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. label Dec 29, 2016
frewsxcv pushed a commit to frewsxcv/rust that referenced this issue Jan 9, 2017
Sign formatting is no longer controlled by a `Signed` trait.  Instead, `pad_integral` is used and implemented for numeric types by default.

Fixes rust-lang#38677
@dbrgn
Copy link
Contributor

dbrgn commented Jan 22, 2017

This can be closed as #38704 is merged, right?

@cbreeden
Copy link
Contributor Author

Yup, forgot about that, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
Projects
None yet
Development

No branches or pull requests

4 participants