doc.rust-lang.org
pub const fn err(self) -> Option<E>
Converts from Result<T, E> to Option<E>.
method
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn copied(self) -> Result<T, E>
Maps a Result<&T, E> to a Result<T, E> by copying the contents of the Ok part.
method
core
Stable since 1.59.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn cloned(self) -> Result<T, E>
Maps a Result<&T, E> to a Result<T, E> by cloning the contents of the Ok part.
method
core
Stable since 1.59.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn as_ref(&self) -> Result<&T, &E>
Converts from &Result<T, E> to Result<&T, &E>.
method
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn as_mut(&mut self) -> Result<&mut T, &mut E>
Converts from &mut Result<T, E> to Result<&mut T, &mut E>.
method
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn as_deref_mut(&mut self) -> Result<&mut <T as >::Target, &mut E>
Converts from Result<T, E> (or &mut Result<T, E>) to Result<&mut <T as DerefMut>::Target, &mut E>.
method
core
Stable since 1.47.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn as_deref(&self) -> Result<&<T as >::Target, &E>
Converts from Result<T, E> (or &Result<T, E>) to Result<&<T as Deref>::Target, &E>.
method
core
Stable since 1.47.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn and_then<U, F>(self, op: F) -> Result<U, E>
Calls op if the result is Ok, otherwise returns the Err value of self.
method
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn and<U>(self, res: Result<U, E>) -> Result<U, E>
Returns res if the result is Ok, otherwise returns the Err value of self.
method
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub enum Result<T, E>
Result is a type that represents either success (Ok) or failure (Err).
enum
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct IterMut<'a, T>
An iterator over a mutable reference to the Ok variant of a Result.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct Iter<'a, T>
An iterator over a reference to the Ok variant of a Result.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct IntoIter<T>
An iterator over the value in a Ok variant of a Result.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub mod result
Error handling with the Result type.
module
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn static_ref(r: &'static T) -> Pin<&'static T>
Gets a pinning reference from a &'static reference.
associated_function
core
Stable since 1.61.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn static_mut(r: &'static mut T) -> Pin<&'static mut T>
Gets a pinning mutable reference from a static mutable reference.
associated_function
core
Stable since 1.61.0
Version 1.100.0-nightly
doc.rust-lang.org
pub unsafe fn map_unchecked_mut<U, F>(self, func: F) -> Pin<&'a mut U>
Constructs a new pin by mapping the interior value.
method
core
Stable since 1.33.0
Version 1.100.0-nightly
doc.rust-lang.org
pub unsafe fn map_unchecked<U, F>(self, func: F) -> Pin<&'a U>
Constructs a new pin by mapping the interior value.
method
core
Stable since 1.33.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn into_ref(self) -> Pin<&'a T>
Converts this Pin<&mut T> into a Pin<&T> with the same lifetime.
method
core
Stable since 1.33.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const unsafe fn get_unchecked_mut(self) -> &'a mut T
Gets a mutable reference to the data inside of this Pin.
method
core
Stable since 1.33.0
Version 1.100.0-nightly