Explain why immediately dropping a JoinGuard is not what you want to do

This commit is contained in:
Jake Goulding 2015-03-11 20:10:52 -04:00
parent cfea8ec416
commit ac6cd90af1

View File

@ -635,7 +635,7 @@ impl Drop for JoinHandle {
/// Due to platform restrictions, it is not possible to `Clone` this
/// handle: the ability to join a child thread is a uniquely-owned
/// permission.
#[must_use]
#[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> {
inner: JoinInner<T>,