Skip to content

Commit

Permalink
Rollup merge of #95130 - workingjubilee:stably-finished, r=m-ou-se
Browse files Browse the repository at this point in the history
Stabilize thread::is_finished

Closes #90470.

r? `@m-ou-se`
  • Loading branch information
Dylan-DPC authored Mar 31, 2022
2 parents a39ac5a + 25eb060 commit 32c5a57
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
2 changes: 1 addition & 1 deletion library/std/src/thread/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1471,7 +1471,7 @@ impl<T> JoinHandle<T> {
///
/// This function does not block. To block while waiting on the thread to finish,
/// use [`join`][Self::join].
#[unstable(feature = "thread_is_running", issue = "90470")]
#[stable(feature = "thread_is_running", since = "1.61.0")]
pub fn is_finished(&self) -> bool {
Arc::strong_count(&self.0.packet) == 1
}
Expand Down
1 change: 0 additions & 1 deletion library/std/src/thread/scoped.rs
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,6 @@ impl<'scope, T> ScopedJoinHandle<'scope, T> {
///
/// This function does not block. To block while waiting on the thread to finish,
/// use [`join`][Self::join].
#[unstable(feature = "thread_is_running", issue = "90470")]
pub fn is_finished(&self) -> bool {
Arc::strong_count(&self.0.packet) == 1
}
Expand Down

0 comments on commit 32c5a57

Please sign in to comment.