Skip to content

Rollup of 5 pull requests #96974

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

Merged
merged 15 commits into from
May 12, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
to_timespec could be unused by some targets
semarie committed May 11, 2022
commit 42f8e1f879487e3b0a48b9635eac11aaf7b672a1
1 change: 1 addition & 0 deletions library/std/src/sys/unix/time.rs
Original file line number Diff line number Diff line change
@@ -125,6 +125,7 @@ impl Timespec {
Some(Timespec::new(secs, nsec as i64))
}

#[allow(dead_code)]
pub fn to_timespec(&self) -> Option<libc::timespec> {
Some(libc::timespec {
tv_sec: self.tv_sec.try_into().ok()?,