Rust Search

Find the best content on Rust, curated by the community; a search engine for Rustaceans.
doc.rust-lang.org
pub const unsafe fn get_unchecked_mut<I>(&mut self, index: I) -> &mut <I as >::Output
Returns a mutable reference to an element or subslice, without doing bounds checking.
method core Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub const unsafe fn get_unchecked<I>(&self, index: I) -> &<I as >::Output
Returns a reference to an element or subslice, without doing bounds checking.
method core Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub const fn get_mut<I>(&mut self, index: I) -> Option<&mut <I as >::Output>
Returns a mutable reference to an element or subslice depending on the type of index (see get) or None if the index is out of bounds.
method core Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub unsafe fn get_disjoint_unchecked_mut<I, const N: usize>(&mut self, indices: [I; N]) -> [&mut <I as >::Output; N]
Returns mutable references to many indices at once, without doing any checks.
method core Stable since 1.86.0 Version 1.100.0-nightly
doc.rust-lang.org
pub fn get_disjoint_mut<I, const N: usize>(&mut self, indices: [I; N]) -> Result<[&mut <I as >::Output; N], GetDisjointMutError>
Returns mutable references to many indices at once.
method core Stable since 1.86.0 Version 1.100.0-nightly
doc.rust-lang.org
pub const fn get<I>(&self, index: I) -> Option<&<I as >::Output>
Returns a reference to an element or subslice depending on the type of index.
method core Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub const fn first_mut(&mut self) -> Option<&mut T>
Returns a mutable reference to the first element of the slice, or None if it is empty.
method core Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub const fn first_chunk_mut<const N: usize>(&mut self) -> Option<&mut [T; N]>
Returns a mutable array reference to the first N items in the slice.
method core Stable since 1.77.0 Version 1.100.0-nightly
doc.rust-lang.org
pub const fn first_chunk<const N: usize>(&self) -> Option<&[T; N]>
Returns an array reference to the first N items in the slice.
method core Stable since 1.77.0 Version 1.100.0-nightly
doc.rust-lang.org
pub const fn first(&self) -> Option<&T>
Returns the first element of the slice, or None if it is empty.
method core Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub fn fill_with<F>(&mut self, f: F)
Fills self with elements returned by calling a closure repeatedly.
method core Stable since 1.51.0 Version 1.100.0-nightly
doc.rust-lang.org
pub fn fill(&mut self, value: T)
Fills self with elements by cloning value.
method core Stable since 1.50.0 Version 1.100.0-nightly
doc.rust-lang.org
pub fn escape_ascii(&self) -> EscapeAscii<'_>
Returns an iterator that produces an escaped version of this slice, treating it as an ASCII string.
method core Stable since 1.60.0 Version 1.100.0-nightly
doc.rust-lang.org
pub const fn eq_ignore_ascii_case(&self, other: &[u8]) -> bool
Checks that two slices are an ASCII case-insensitive match.
method core Stable since 1.23.0 Version 1.100.0-nightly
doc.rust-lang.org
pub fn ends_with(&self, needle: &[T]) -> bool
Returns true if needle is a suffix of the slice or equal to the slice.
method core Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub fn element_offset(&self, element: &T) -> Option<usize>
Returns the index that an element reference points to.
method core Stable since 1.94.0 Version 1.100.0-nightly
doc.rust-lang.org
pub fn copy_within<R>(&mut self, src: R, dest: usize)
Copies elements from one part of the slice to another part of itself, using a memmove.
method core Stable since 1.37.0 Version 1.100.0-nightly
doc.rust-lang.org
pub const fn copy_from_slice(&mut self, src: &[T])
Copies all elements from src into self, using a memcpy.
method core Stable since 1.9.0 Version 1.100.0-nightly
doc.rust-lang.org
pub fn contains(&self, x: &T) -> bool
Returns true if the slice contains an element with the given value.
method core Stable since 1.0.0 Version 1.100.0-nightly
doc.rust-lang.org
pub const fn clone_from_slice(&mut self, src: &[T])
Copies the elements from src into self.
method core Stable since 1.7.0 Version 1.100.0-nightly
"If a normal add is [a waffle iron ](https://en.wikipedia.org/wiki/Waffle_iron), SIMD add is a double or quadruple waffle iron. You can make 2 or 4 or ..."

Search tips

Type anything to search across articles, videos (including conference talks), podcasts, research, crates, and Rust API documentation. These operators give you finer control — click an example to try it.

Find pages containing all your words. Pages where the words appear together rank higher.
Quote part of your query to keep those words together as an exact phrase within a larger search.
Wrap the whole query in quotes for a verbatim search that matches text exactly, punctuation and all — perfect for Rust syntax. Needs at least 3 characters.
Put ! first to open the top result immediately. Quote the whole query for a literal leading bang, as in '!Send'. Bangs elsewhere, such as println!, stay literal. Browser and launcher shortcuts can invoke this directly. See search integrations.
Limit results to a single site. Works on its own () too. One site: per search.

Use the tabs and filters above the results to narrow by content type, publication year, and sort order.