Skip to content

Commit 049ccbb

Browse files
author
Vasya Novikov
committed
update wording for std::thread::sleep
1 parent 1a605a6 commit 049ccbb

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/libstd/thread/mod.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -650,15 +650,15 @@ pub fn panicking() -> bool {
650650
panicking::panicking()
651651
}
652652

653-
/// Puts the current thread to sleep for the specified amount of time.
653+
/// Puts the current thread to sleep for at least the specified amount of time.
654654
///
655655
/// The thread may sleep longer than the duration specified due to scheduling
656-
/// specifics or platform-dependent functionality.
656+
/// specifics or platform-dependent functionality. It will never sleep less.
657657
///
658658
/// # Platform-specific behavior
659659
///
660-
/// On Unix platforms this function might return early due to a
661-
/// signal being received or a spurious wakeup.
660+
/// On Unix platforms this function may invoke multiple syscalls
661+
/// in case of a signal being received or a spurious wakeup.
662662
///
663663
/// # Examples
664664
///

0 commit comments

Comments
 (0)