-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
A-docsArea: Documentation for any part of the project, including the compiler, standard library, and toolsArea: Documentation for any part of the project, including the compiler, standard library, and tools
Description
Location
Lines 355 to 361 in 57781b2
/// Returns the amount of time elapsed since this instant was created. | |
/// | |
/// # Panics | |
/// | |
/// Previous rust versions panicked when self was earlier than the current time. Currently this | |
/// method returns a Duration of zero in that case. Future versions may reintroduce the panic. | |
/// See [Monotonicity]. |
Summary
This is part of the documentation for std::time::Instant::elapsed
. The Panics section on line 359 says:
Previous rust versions panicked when self was earlier than the current time.
Which is obviously not the case. It should be:
Previous rust versions panicked when the current time was earlier than self.
Metadata
Metadata
Assignees
Labels
A-docsArea: Documentation for any part of the project, including the compiler, standard library, and toolsArea: Documentation for any part of the project, including the compiler, standard library, and tools