Skip to content

Commit

Permalink
add 'T: Send' to Send/Sync impls. fixes #9
Browse files Browse the repository at this point in the history
  • Loading branch information
JOE1994 committed Jan 22, 2021
1 parent 4428433 commit 1e462c3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/lib.rs
Expand Up @@ -76,9 +76,9 @@ impl<T> Drop for QueueSender<T> {
}
}

unsafe impl<T> Sync for QueueSender<T> {}
unsafe impl<T: Send> Sync for QueueSender<T> {}

unsafe impl<T> Send for QueueSender<T> {}
unsafe impl<T: Send> Send for QueueSender<T> {}

/// A `QueueReceiver` is used to pop previously
/// pushed items from the queue.
Expand Down Expand Up @@ -181,7 +181,7 @@ impl<T> Drop for QueueReceiver<T> {
}
}

unsafe impl<T> Send for QueueReceiver<T> {}
unsafe impl<T: Send> Send for QueueReceiver<T> {}

pub struct Queue;

Expand Down

0 comments on commit 1e462c3

Please sign in to comment.