Skip to content

Commit

Permalink
Rollup merge of #68161 - ruuda:fix-instant-docs, r=rkruppe
Browse files Browse the repository at this point in the history
Fix system call docs for time::Instant

The link for UNIX was pointing to the Cloud ABI docs. It should have been pointing to the `clock_gettime` docs instead. A similar table is repeated in the docs for `SystemTime`, but there the UNIX entry was already correct.

`clock_gettime(CLOCK_MONOTONIC)` is the current implementation: https://github.com/rust-lang/rust/blob/3ebcfa1451cfedc13a07e6353d8ade9742dfdc2a/src/libstd/sys/unix/time.rs#L274
https://github.com/rust-lang/rust/blob/3ebcfa1451cfedc13a07e6353d8ade9742dfdc2a/src/libstd/sys/unix/time.rs#L348-L352

r? @steveklabnik
  • Loading branch information
JohnTitor authored Jan 13, 2020
2 parents 574ef55 + 827ee7a commit 87bdc8e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/libstd/time.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ pub use core::time::Duration;
/// |:---------:|:--------------------------------------------------------------------:|
/// | Cloud ABI | [clock_time_get (Monotonic Clock)] |
/// | SGX | [`insecure_time` usercall]. More information on [timekeeping in SGX] |
/// | UNIX | [clock_time_get (Monotonic Clock)] |
/// | UNIX | [clock_gettime (Monotonic Clock)] |
/// | Darwin | [mach_absolute_time] |
/// | VXWorks | [clock_gettime (Monotonic Clock)] |
/// | WASI | [__wasi_clock_time_get (Monotonic Clock)] |
Expand Down

0 comments on commit 87bdc8e

Please sign in to comment.