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

Move {f32,f64}::clamp to core. #79473

Merged
merged 1 commit into from
Dec 20, 2020
Merged

Move {f32,f64}::clamp to core. #79473

merged 1 commit into from
Dec 20, 2020

Conversation

m-ou-se
Copy link
Member

@m-ou-se m-ou-se commented Nov 27, 2020

clamp was recently stabilized (tracking issue: #44095). But although Ord::clamp was added in core (because Ord is in core), the versions for the f32 and f64 primitives were added in std (together with floor, sin, etc.), not in core (together with min, max, from_bits, etc.).

This change moves them to core, such that clamp on floats is available in no_std programs as well.

@m-ou-se m-ou-se added A-floating-point Area: Floating point numbers and arithmetic T-libs-api Relevant to the library API team, which will review and decide on the PR/issue. labels Nov 27, 2020
@m-ou-se
Copy link
Member Author

m-ou-se commented Nov 27, 2020

@rfcbot merge

@rfcbot
Copy link

rfcbot commented Nov 27, 2020

Team member @m-ou-se has proposed to merge this. The next step is review by the rest of the tagged team members:

No concerns currently listed.

Once a majority of reviewers approve (and at most 2 approvals are outstanding), this will enter its final comment period. If you spot a major issue that hasn't been raised at any point in this process, please speak up!

See this document for info about what commands tagged team members can give me.

@rfcbot rfcbot added proposed-final-comment-period Proposed to merge/close by relevant subteam, see T-<team> label. Will enter FCP once signed off. disposition-merge This issue / PR is in PFCP or FCP with a disposition to merge it. labels Nov 27, 2020
@rfcbot rfcbot added final-comment-period In the final comment period and will be merged soon unless new substantive objections are raised. and removed proposed-final-comment-period Proposed to merge/close by relevant subteam, see T-<team> label. Will enter FCP once signed off. labels Dec 9, 2020
@rfcbot
Copy link

rfcbot commented Dec 9, 2020

🔔 This is now entering its final comment period, as per the review above. 🔔

@rfcbot rfcbot added finished-final-comment-period The final comment period is finished for this PR / Issue. to-announce Announce this issue on triage meeting and removed final-comment-period In the final comment period and will be merged soon unless new substantive objections are raised. labels Dec 19, 2020
@rfcbot
Copy link

rfcbot commented Dec 19, 2020

The final comment period, with a disposition to merge, as per the review above, is now complete.

As the automated representative of the governance process, I would like to thank the author for their work and everyone else who contributed.

The RFC will be merged soon.

@m-ou-se
Copy link
Member Author

m-ou-se commented Dec 19, 2020

@bors r+

@bors
Copy link
Contributor

bors commented Dec 19, 2020

📌 Commit 0523eeb has been approved by m-ou-se

@bors bors added the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Dec 19, 2020
@bors
Copy link
Contributor

bors commented Dec 19, 2020

⌛ Testing commit 0523eeb with merge c1d5843...

@bors
Copy link
Contributor

bors commented Dec 20, 2020

☀️ Test successful - checks-actions
Approved by: m-ou-se
Pushing c1d5843 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Dec 20, 2020
@bors bors merged commit c1d5843 into rust-lang:master Dec 20, 2020
@rustbot rustbot added this to the 1.50.0 milestone Dec 20, 2020
@m-ou-se m-ou-se deleted the clamp-in-core branch December 22, 2020 21:08
@spastorino spastorino removed the to-announce Announce this issue on triage meeting label Dec 31, 2020
@pthariensflame
Copy link
Contributor

Does this need relnotes?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-floating-point Area: Floating point numbers and arithmetic disposition-merge This issue / PR is in PFCP or FCP with a disposition to merge it. finished-final-comment-period The final comment period is finished for this PR / Issue. merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-libs-api Relevant to the library API team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants