Skip to content

Commit

Permalink
Add send & sync for mutex
Browse files Browse the repository at this point in the history
  • Loading branch information
Mnwa committed Sep 4, 2020
1 parent 68fec30 commit 32ba633
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/mutex.rs
Expand Up @@ -107,6 +107,9 @@ pub struct MutexOwnedGuardFuture<T: ?Sized> {
is_realized: AtomicBool,
}

unsafe impl<T: ?Sized + Send> Send for Mutex<T> {}
unsafe impl<T: ?Sized + Send> Sync for Mutex<T> {}

unsafe impl<T: ?Sized + Send> Send for MutexGuard<'_, T> {}
unsafe impl<T: ?Sized + Send> Sync for MutexGuard<'_, T> {}

Expand Down

0 comments on commit 32ba633

Please sign in to comment.