Skip to content

Commit

Permalink
Rollup merge of #119804 - tmccombs:stabilize-unpoison, r=cuviper
Browse files Browse the repository at this point in the history
Stabilize mutex_unpoison feature

Closes #96469

`@rustbot` +T-libs-api
  • Loading branch information
matthiaskrgr authored Jan 11, 2024
2 parents d37de53 + 1ed855d commit f92cde4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
4 changes: 1 addition & 3 deletions library/std/src/sync/mutex.rs
Original file line number Diff line number Diff line change
Expand Up @@ -383,8 +383,6 @@ impl<T: ?Sized> Mutex<T> {
/// # Examples
///
/// ```
/// #![feature(mutex_unpoison)]
///
/// use std::sync::{Arc, Mutex};
/// use std::thread;
///
Expand All @@ -406,7 +404,7 @@ impl<T: ?Sized> Mutex<T> {
/// assert_eq!(*x, 1);
/// ```
#[inline]
#[unstable(feature = "mutex_unpoison", issue = "96469")]
#[stable(feature = "mutex_unpoison", since = "CURRENT_RUSTC_VERSION")]
pub fn clear_poison(&self) {
self.poison.clear();
}
Expand Down
4 changes: 1 addition & 3 deletions library/std/src/sync/rwlock.rs
Original file line number Diff line number Diff line change
Expand Up @@ -387,8 +387,6 @@ impl<T: ?Sized> RwLock<T> {
/// # Examples
///
/// ```
/// #![feature(mutex_unpoison)]
///
/// use std::sync::{Arc, RwLock};
/// use std::thread;
///
Expand All @@ -410,7 +408,7 @@ impl<T: ?Sized> RwLock<T> {
/// assert_eq!(*guard, 1);
/// ```
#[inline]
#[unstable(feature = "mutex_unpoison", issue = "96469")]
#[stable(feature = "mutex_unpoison", since = "CURRENT_RUSTC_VERSION")]
pub fn clear_poison(&self) {
self.poison.clear();
}
Expand Down

0 comments on commit f92cde4

Please sign in to comment.