-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Open
Labels
C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCCategory: An issue tracking the progress of sth. like the implementation of an RFCE-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.E-help-wantedCall for participation: Help is requested to fix this issue.Call for participation: Help is requested to fix this issue.T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.
Description
Feature gate: #![feature(sync_poison_mod)]
This is a tracking issue moving all poisonable std::sync
types to std::sync::poison
, with reexports in std::sync
. In a future edition, we will be able to instead reexport std::sync::nonpoison
(this module does not exist yet).
Public API
// std::sync::poison
type LockResult;
type TryLockResult;
struct Condvar { /* ... */ };
struct Mutex<T: ?Sized> { /* ... */ };
struct MutexGuard { /* ... */ };
struct Once { /* ... */ };
struct OnceState { /* ... */ };
struct PoisonError { /* ... */ };
struct RwLock { /* ... */ };
struct RwLockReadGuard { /* ... */ };
struct RwLockWriteGuard { /* ... */ };
enum TryLockError { /* ... */ };
// Unstable types
pub struct MappedMutexGuard<'a, T: ?Sized + 'a> { /* ... */ }
pub struct MappedRwLockReadGuard<'a, T: ?Sized + 'a> { /* ... */ }
pub struct MappedRwLockWriteGuard<'a, T: ?Sized + 'a> { /* ... */ }
// std::sync
// This module will be gated behind `sync_poison`
pub mod poison;
pub use poision::*;
Steps / History
- ACP: Adding locks disregarding poison libs-team#169 (comment)
- Implementation: Move some things to
std::sync::poison
and reexport them instd::sync
#134692 - Final comment period (FCP)1
- Stabilization PR
Unresolved Questions
- None yet.
Related
-
nonpoison
versions of existingpoison
types: Tracking Issue forsync_nonpoison
andnonpoison_{condvar,mutex,once,rwlock}
#134645 - Should
LazyLock
be moved? Tracking Issue forsync_poison_mod
#134646 (comment)
Footnotes
FliegendeWurst, connortsui20 and purplesyringa
Metadata
Metadata
Assignees
Labels
C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCCategory: An issue tracking the progress of sth. like the implementation of an RFCE-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.E-help-wantedCall for participation: Help is requested to fix this issue.Call for participation: Help is requested to fix this issue.T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.