-
Notifications
You must be signed in to change notification settings - Fork 265
Open
Description
I have the following requirements:
- I have multiple objects connected via Arc and interior mutability.
- These objects contain mutable data.
- I want all of that data to be protected by a single lock.
- It is ok if the lock only hands out immutable references as long as it maps Send to Sync like ReentrantLock. I can then use cheap, non-Sync interior mutability for the actual mutations.
I've implemented this here on top of the parking_lot RawMutex: https://docs.rs/shared-lock
Do you think it makes sense to support this pattern in parking_lot directly?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels