Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add an owned variant of RwLockReadGuard and RwLockWriteGuard #991

Open
haselkern opened this issue Oct 2, 2021 · 0 comments
Open

Add an owned variant of RwLockReadGuard and RwLockWriteGuard #991

haselkern opened this issue Oct 2, 2021 · 0 comments
Labels
enhancement New feature or request

Comments

@haselkern
Copy link

When locking an Arc<Mutex<...>> I can call lock_arc, which returns an extremely handy owned MutexGuardArc.

I would expect an Arc<RwLock<...>> to provide read_arc and write_arc to return owned guards as well, unfortunately these methods do not exist. They should be possible to implement, since the tokio project does provide such methods.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants