diff options
author | Alice Ryhl <alice@ryhl.io> | 2020-04-04 19:02:26 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-04 19:02:26 +0200 |
commit | 7c1bc460f7eccbeef62504d4799b6bccc909e46c (patch) | |
tree | ec1d848bb94ba5df384884bebae8429a9e5135bc /tokio/src/stream/empty.rs | |
parent | d883ac0fa0c65fdc25bedf5566cb76c236fae3f7 (diff) |
test: add Send/Sync tests for all async fns (#2377)
Also updates Empty and Pending to be unconditionally Send and Sync.
Diffstat (limited to 'tokio/src/stream/empty.rs')
-rw-r--r-- | tokio/src/stream/empty.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tokio/src/stream/empty.rs b/tokio/src/stream/empty.rs index a320d44b..6118673e 100644 --- a/tokio/src/stream/empty.rs +++ b/tokio/src/stream/empty.rs @@ -10,6 +10,8 @@ use core::task::{Context, Poll}; pub struct Empty<T>(PhantomData<T>); impl<T> Unpin for Empty<T> {} +unsafe impl<T> Send for Empty<T> {} +unsafe impl<T> Sync for Empty<T> {} /// Creates a stream that yields nothing. /// |