]> git.lizzy.rs Git - rust.git/commitdiff
Added `T:Send` bound to `JoinGuard<T>` to avoid specialized `Drop` impl.
authorFelix S. Klock II <pnkfelix@pnkfx.org>
Sat, 21 Mar 2015 12:34:33 +0000 (13:34 +0100)
committerFelix S. Klock II <pnkfelix@pnkfx.org>
Tue, 24 Mar 2015 21:27:23 +0000 (22:27 +0100)
src/libstd/thread/mod.rs

index 57baeb1fb74860a8573a47c36ae4db07b51b79c5..27b50fc9aaa60ca0312245161eb46c48b8a8f61e 100644 (file)
@@ -698,7 +698,7 @@ fn drop(&mut self) {
 /// permission.
 #[must_use = "thread will be immediately joined if `JoinGuard` is not used"]
 #[stable(feature = "rust1", since = "1.0.0")]
-pub struct JoinGuard<'a, T: 'a> {
+pub struct JoinGuard<'a, T: Send + 'a> {
     inner: JoinInner<T>,
     _marker: PhantomData<&'a T>,
 }