libsw_core/instant_impls/
std_instant.rs1extern crate std;
6
7use ::core::time::Duration;
8
9use crate::Instant;
10
11impl Instant for ::std::time::Instant {
12 fn now() -> Self {
13 Self::now()
14 }
15
16 fn checked_add(&self, duration: Duration) -> Option<Self> {
17 self.checked_add(duration)
18 }
19
20 fn checked_sub(&self, duration: Duration) -> Option<Self> {
21 self.checked_sub(duration)
22 }
23
24 fn saturating_duration_since(&self, earlier: Self) -> Duration {
25 self.saturating_duration_since(earlier)
26 }
27}