# Trait std::marker::Send 1.0.0 [−] [src]

    #[lang = "send"]
    pub unsafe trait Send { }

Types that can be transferred across thread boundaries.

This trait is automatically implemented when the compiler determines it's appropriate.

An example of a non-`Send` type is the reference-counting pointer `rc::Rc`. If two threads attempt to clone `Rc`s that point to the same reference-counted value, they might try to update the reference count at the same time, which is undefined behavior because `Rc` doesn't use atomic operations. Its cousin `sync::Arc` does use atomic operations (incurring some overhead) and thus is `Send`.

See the Nomicon for more details.

## Implementors

- `impl<T> Send for Cell<T> where
  T: Send,`
- `impl<T> !Send for *const T where
  T: ?Sized,`
- `impl<'a, T> Send for &'a mut T where
  T: Send + ?Sized,`
- `impl<T> !Send for *mut T where
  T: ?Sized,`
- `impl<'a, T> Send for &'a T where
  T: Sync + ?Sized,`
- `impl<'a, T> Send for std::slice::IterMut<'a, T> where
  T: Send,`
- `impl<'a, T> Send for std::slice::Iter<'a, T> where
  T: Sync,`
- `impl<T> Send for RefCell<T> where
  T: Send + ?Sized,`
- `impl<T> Send for Unique<T> where
  T: Send + ?Sized,`
- `impl<T> !Send for Shared<T> where
  T: ?Sized,`
- `impl<T> Send for AtomicPtr<T>`
- `impl<'a, T> Send for std::vec::Drain<'a, T> where
  T: Send,`
- `impl<'a, T> Send for std::collections::linked_list::Iter<'a, T> where
  T: Sync,`
- `impl<'a> Send for std::string::Drain<'a>`
- `impl<T> !Send for std::rc::Weak<T> where
  T: ?Sized,`
- `impl<T> Send for Arc<T> where
  T: Send + Sync + ?Sized,`
- `impl<'a, T> Send for std::collections::vec_deque::Drain<'a, T> where
  T: Send,`
- `impl<T> Send for IntoIter<T> where
  T: Send,`
- `impl<T> Send for std::sync::Weak<T> where
  T: Send + Sync + ?Sized,`
- `impl<T> Send for LinkedList<T> where
  T: Send,`
- `impl<T> !Send for Rc<T> where
  T: ?Sized,`
- `impl<'a, T> Send for std::collections::linked_list::IterMut<'a, T> where
  T: Send,`
- `impl !Send for Select`
- `impl<T: Send> Send for Receiver<T>`
- `impl<T: Send> Send for Sender<T>`
- `impl<T: Send> Send for SyncSender<T>`
- `impl<T: ?Sized + Send> Send for Mutex<T>`
- `impl<'a, T: ?Sized> !Send for MutexGuard<'a, T>`
- `impl Send for Once`
- `impl<T: ?Sized + Send + Sync> Send for RwLock<T>`
- `impl<'a, T: ?Sized> !Send for RwLockReadGuard<'a, T>`
- `impl<'a, T: ?Sized> !Send for RwLockWriteGuard<'a, T>`

# Help

## Keyboard Shortcuts

?
  Show this help dialog
S
  Focus the search field
⇤
  Move up in search results
⇥
  Move down in search results
⏎
  Go to active search result
+
  Collapse/expand all sections

## Search Tricks

Prefix searches with a type followed by a colon (e.g. `fn:`) to restrict the search to a given type.

Accepted types are: `fn`, `mod`, `struct`, `enum`, `trait`, `type`, `macro`, and `const`.

Search functions by type signature (e.g. `vec -> usize` or `* -> vec`)