diff options
| author | Michael Layzell <michael@thelayzells.com> | 2015-09-24 18:19:23 -0400 |
|---|---|---|
| committer | Michael Layzell <michael@thelayzells.com> | 2015-10-08 09:49:32 -0400 |
| commit | 493355d8e92ab00f0f6b787e4226c095ccd83a55 (patch) | |
| tree | e9cc4591e5e0ea3d3e560ec07a07aa44c53c2432 /src/libcollections | |
| parent | 45be6fc4d755b1376942196edc9efc7b62a43808 (diff) | |
| download | rust-493355d8e92ab00f0f6b787e4226c095ccd83a55.tar.gz rust-493355d8e92ab00f0f6b787e4226c095ccd83a55.zip | |
Add unsafe Send and Sync impls to VecDeque's Drain<T>
Diffstat (limited to 'src/libcollections')
| -rw-r--r-- | src/libcollections/vec_deque.rs | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/libcollections/vec_deque.rs b/src/libcollections/vec_deque.rs index 27a996055f5..807c02af6e1 100644 --- a/src/libcollections/vec_deque.rs +++ b/src/libcollections/vec_deque.rs @@ -1800,6 +1800,9 @@ pub struct Drain<'a, T: 'a> { deque: *mut VecDeque<T>, } +unsafe impl<'a, T: Sync> Sync for Drain<'a, T> {} +unsafe impl<'a, T: Send> Send for Drain<'a, T> {} + #[stable(feature = "rust1", since = "1.0.0")] impl<'a, T: 'a> Drop for Drain<'a, T> { fn drop(&mut self) { |
