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

Tracking issue for div_duration #63139

Closed
newpavlov opened this issue Jul 30, 2019 · 7 comments · Fixed by #124667
Closed

Tracking issue for div_duration #63139

newpavlov opened this issue Jul 30, 2019 · 7 comments · Fixed by #124667
Labels
A-time Area: Time B-unstable Blocker: Implemented in the nightly compiler and unstable. C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC Libs-Small Libs issues that are considered "small" or self-contained Libs-Tracked Libs issues that are tracked on the team's project board. requires-nightly This issue requires a nightly compiler in some way. T-libs-api Relevant to the library API team, which will review and decide on the PR/issue.

Comments

@newpavlov
Copy link
Contributor

Rust PR: #62756

This feature adds the following methods to Duration:

  • div_duration_f64(self, rhs: Duration) -> f64
  • div_duration_f32(self, rhs: Duration) -> f32
@jonas-schievink jonas-schievink added B-unstable Blocker: Implemented in the nightly compiler and unstable. C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC T-libs-api Relevant to the library API team, which will review and decide on the PR/issue. labels Jul 30, 2019
@Centril Centril added the requires-nightly This issue requires a nightly compiler in some way. label Jul 30, 2019
@jhpratt
Copy link
Member

jhpratt commented Feb 18, 2020

Anything in particular holding up the stabilization here? The implementation is trivial and docs lgtm.

@Demi-Marie
Copy link

I would like to add methods that return an exact u128, but that can wait.

@KodrAus
Copy link
Contributor

KodrAus commented Jul 29, 2020

These methods are a little odd, but seem reasonable to me following the example given: #62756 (comment)

@KodrAus KodrAus added I-nominated Libs-Small Libs issues that are considered "small" or self-contained Libs-Tracked Libs issues that are tracked on the team's project board. labels Jul 29, 2020
@Rua
Copy link
Contributor

Rua commented Sep 30, 2020

Given how straightforward these methods are, I don't think there's any problem stabilising them?

@KodrAus
Copy link
Contributor

KodrAus commented Oct 23, 2020

They're straightforward in implementation, but conceptually tricky at a glance. I think the docs will need some fleshing out before stabilizing but I don't have any other concerns if somebody wants to write a PR!

@KodrAus KodrAus added the A-time Area: Time label Jan 6, 2021
@workingjubilee
Copy link
Member

workingjubilee commented Apr 10, 2021

This needs more testing with various interesting values that could produce interesting floating point numbers, and should not be stabilized without such.

@Xaeroxe
Copy link
Contributor

Xaeroxe commented Jan 7, 2023

#106570 tests were added in this PR

JohnTitor pushed a commit to JohnTitor/rust that referenced this issue Jan 10, 2023
…Titor

add tests for div_duration_* functions

Per rust-lang#63139 (comment)

this adds unit tests for the functions that will hopefully effectively demonstrate that `div_duration` is ready to be stabilized.
Noratrieb added a commit to Noratrieb/rust that referenced this issue Jan 11, 2023
…Titor

add tests for div_duration_* functions

Per rust-lang#63139 (comment)

this adds unit tests for the functions that will hopefully effectively demonstrate that `div_duration` is ready to be stabilized.
Noratrieb added a commit to Noratrieb/rust that referenced this issue Jan 11, 2023
…Titor

add tests for div_duration_* functions

Per rust-lang#63139 (comment)

this adds unit tests for the functions that will hopefully effectively demonstrate that `div_duration` is ready to be stabilized.
thomcc pushed a commit to tcdi/postgrestd that referenced this issue May 31, 2023
add tests for div_duration_* functions

Per rust-lang/rust#63139 (comment)

this adds unit tests for the functions that will hopefully effectively demonstrate that `div_duration` is ready to be stabilized.
@bors bors closed this as completed in 80aea30 May 26, 2024
rust-timer added a commit to rust-lang-ci/rust that referenced this issue May 26, 2024
Rollup merge of rust-lang#124667 - newpavlov:stabilize_div_duration, r=jhpratt

Stabilize `div_duration`

Closes rust-lang#63139
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-time Area: Time B-unstable Blocker: Implemented in the nightly compiler and unstable. C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC Libs-Small Libs issues that are considered "small" or self-contained Libs-Tracked Libs issues that are tracked on the team's project board. requires-nightly This issue requires a nightly compiler in some way. T-libs-api Relevant to the library API team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

10 participants