-
Notifications
You must be signed in to change notification settings - Fork 13.9k
Improve core::cmp docs #21990
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
Improve core::cmp docs #21990
Conversation
|
r? @aturon (rust_highfive has picked a reviewer for you, use r? to override) |
src/libcore/cmp.rs
Outdated
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 think s/and so/therefore/ would sound better here.
7be82c7 to
2307a5c
Compare
|
Feedback addressed. |
src/libcore/cmp.rs
Outdated
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.
Maybe s/Traits/Functionality/ since there's things other than traits? (I could just be overly nit-picky)
bc812af to
c378c07
Compare
src/libcore/cmp.rs
Outdated
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.
s/is often/can be/
c378c07 to
679f6a4
Compare
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.
Similarly these could demonstrate returning None, also using NaN.
(Totally minor: Is there a reason that these ones have cmp::partial_min(2, 2) but the non-partial ones don't?)
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 thought I was making them all the same, but it's possible that i just screwed tha tup
956558f to
7c63cd1
Compare
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.
This could have a NaN example too.
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.
truth. fixed!
7c63cd1 to
3d06e91
Compare
src/libcore/cmp.rs
Outdated
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.
This and partial_max should be function calls, not methods.
3d06e91 to
17f9d36
Compare
|
@huonw should be good to go now |
|
@bors r+ 17f9 rollup |
Fix up, add examples, make them all the same.
Fix up, add examples, make them all the same.