@@ -97,7 +97,6 @@ pub use core::time::Duration;
97
97
/// [clock_time_get (Monotonic Clock)]: https://nuxi.nl/cloudabi/#clock_time_get
98
98
///
99
99
/// **Disclaimer:** These system calls might change over time.
100
- ///
101
100
#[ derive( Copy , Clone , PartialEq , Eq , PartialOrd , Ord , Hash ) ]
102
101
#[ stable( feature = "time2" , since = "1.8.0" ) ]
103
102
pub struct Instant ( time:: Instant ) ;
@@ -125,11 +124,6 @@ pub struct Instant(time::Instant);
125
124
/// The size of a `SystemTime` struct may vary depending on the target operating
126
125
/// system.
127
126
///
128
- /// [`Instant`]: ../../std/time/struct.Instant.html
129
- /// [`Result`]: ../../std/result/enum.Result.html
130
- /// [`Duration`]: ../../std/time/struct.Duration.html
131
- /// [`UNIX_EPOCH`]: ../../std/time/constant.UNIX_EPOCH.html
132
- ///
133
127
/// Example:
134
128
///
135
129
/// ```no_run
@@ -176,7 +170,6 @@ pub struct Instant(time::Instant);
176
170
/// [GetSystemTimeAsFileTime]: https://docs.microsoft.com/en-us/windows/win32/api/sysinfoapi/nf-sysinfoapi-getsystemtimeasfiletime
177
171
///
178
172
/// **Disclaimer:** These system calls might change over time.
179
- ///
180
173
#[ derive( Copy , Clone , PartialEq , Eq , PartialOrd , Ord , Hash ) ]
181
174
#[ stable( feature = "time2" , since = "1.8.0" ) ]
182
175
pub struct SystemTime ( time:: SystemTime ) ;
@@ -368,7 +361,7 @@ impl Add<Duration> for Instant {
368
361
/// This function may panic if the resulting point in time cannot be represented by the
369
362
/// underlying data structure. See [`checked_add`] for a version without panic.
370
363
///
371
- /// [`checked_add`]: ../../std/time/struct. Instant.html#method. checked_add
364
+ /// [`checked_add`]: Instant:: checked_add
372
365
fn add ( self , other : Duration ) -> Instant {
373
366
self . checked_add ( other) . expect ( "overflow when adding duration to instant" )
374
367
}
@@ -463,11 +456,6 @@ impl SystemTime {
463
456
/// Returns an [`Err`] if `earlier` is later than `self`, and the error
464
457
/// contains how far from `self` the time is.
465
458
///
466
- /// [`Ok`]: ../../std/result/enum.Result.html#variant.Ok
467
- /// [`Duration`]: ../../std/time/struct.Duration.html
468
- /// [`Err`]: ../../std/result/enum.Result.html#variant.Err
469
- /// [`Instant`]: ../../std/time/struct.Instant.html
470
- ///
471
459
/// # Examples
472
460
///
473
461
/// ```
@@ -497,11 +485,6 @@ impl SystemTime {
497
485
/// Returns an [`Err`] if `self` is later than the current system time, and
498
486
/// the error contains how far from the current system time `self` is.
499
487
///
500
- /// [`Ok`]: ../../std/result/enum.Result.html#variant.Ok
501
- /// [`Duration`]: ../../std/time/struct.Duration.html
502
- /// [`Err`]: ../../std/result/enum.Result.html#variant.Err
503
- /// [`Instant`]: ../../std/time/struct.Instant.html
504
- ///
505
488
/// # Examples
506
489
///
507
490
/// ```no_run
@@ -544,7 +527,7 @@ impl Add<Duration> for SystemTime {
544
527
/// This function may panic if the resulting point in time cannot be represented by the
545
528
/// underlying data structure. See [`checked_add`] for a version without panic.
546
529
///
547
- /// [`checked_add`]: ../../std/time/struct. SystemTime.html#method. checked_add
530
+ /// [`checked_add`]: SystemTime:: checked_add
548
531
fn add ( self , dur : Duration ) -> SystemTime {
549
532
self . checked_add ( dur) . expect ( "overflow when adding duration to instant" )
550
533
}
@@ -589,8 +572,6 @@ impl fmt::Debug for SystemTime {
589
572
/// measurement lies, and using `UNIX_EPOCH + duration` can be used to create a
590
573
/// [`SystemTime`] instance to represent another fixed point in time.
591
574
///
592
- /// [`SystemTime`]: ../../std/time/struct.SystemTime.html
593
- ///
594
575
/// # Examples
595
576
///
596
577
/// ```no_run
@@ -608,13 +589,9 @@ impl SystemTimeError {
608
589
/// Returns the positive duration which represents how far forward the
609
590
/// second system time was from the first.
610
591
///
611
- /// A `SystemTimeError` is returned from the [`duration_since`] and [`elapsed`]
612
- /// methods of [`SystemTime`] whenever the second system time represents a point later
613
- /// in time than the `self` of the method call.
614
- ///
615
- /// [`duration_since`]: ../../std/time/struct.SystemTime.html#method.duration_since
616
- /// [`elapsed`]: ../../std/time/struct.SystemTime.html#method.elapsed
617
- /// [`SystemTime`]: ../../std/time/struct.SystemTime.html
592
+ /// A `SystemTimeError` is returned from the [`SystemTime::duration_since`]
593
+ /// and [`SystemTime::elapsed`] methods whenever the second system time
594
+ /// represents a point later in time than the `self` of the method call.
618
595
///
619
596
/// # Examples
620
597
///
0 commit comments