Struct IterMut

pub struct IterMut<'a, A: 'a> { pub(in ::option) inner: Item<&'a mut A> }

An iterator over a mutable reference to the Some variant of an Option.

The iterator yields one value if the Option is a Some, otherwise none.

This struct is created by the Option::iter_mut function.

Fields

inner: Item<&'a mut A>

Trait Implementations

impl<'a, A> DoubleEndedIterator for IterMut<'a, A>

fn next_back(&mut self) -> Option<&'a mut A>

impl<'a, A> Iterator for IterMut<'a, A>

type Item = &'a mut A;
fn next(&mut self) -> Option<&'a mut A>
fn size_hint(&self) -> (usize, Option<usize>)

impl<'a, A: Debug + 'a> Debug for IterMut<'a, A>

fn fmt(&self, f: &mut Formatter<'_>) -> Result

impl<A> ExactSizeIterator for IterMut<'_, A>

impl<A> FusedIterator for IterMut<'_, A>

impl<A> TrustedLen for IterMut<'_, A>

impl<T> OneShot for IterMut<'_, T>

Auto Trait Implementations

impl<'a, A> !UnwindSafe for IterMut<'a, A>

impl<'a, A> Freeze for IterMut<'a, A> where Item<&'a mut A>: Freeze,

impl<'a, A> RefUnwindSafe for IterMut<'a, A> where Item<&'a mut A>: RefUnwindSafe,

impl<'a, A> Send for IterMut<'a, A> where Item<&'a mut A>: Send,

impl<'a, A> Sync for IterMut<'a, A> where Item<&'a mut A>: Sync,

impl<'a, A> Unpin for IterMut<'a, A> where Item<&'a mut A>: Unpin,

impl<'a, A> UnsafeUnpin for IterMut<'a, A> where Item<&'a mut A>: UnsafeUnpin,

Blanket Implementations

impl<I> IntoIterator for IterMut<'a, A> where I: Iterator,

type Item = <I as Iterator>::Item;
type IntoIter = I;
fn into_iter(self) -> I

impl<T> Any for IterMut<'a, A> where T: 'static + ?Sized,

fn type_id(&self) -> TypeId

impl<T> Borrow<T> for IterMut<'a, A> where T: ?Sized,

fn borrow(&self) -> &T

impl<T> BorrowMut<T> for IterMut<'a, A> where T: ?Sized,

fn borrow_mut(&mut self) -> &mut T

impl<T> From<T> for IterMut<'a, A>

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> SizeHint for IterMut<'a, A> where T: ?Sized,

fn lower_bound(&self) -> usize
fn upper_bound(&self) -> Option<usize>

impl<T> SizedTypeProperties for IterMut<'a, A>

impl<T, U> Into<U> for IterMut<'a, A> where U: From<T>,

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom<U> for IterMut<'a, A> where U: Into<T>,

type Error = Infallible;
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

impl<T, U> TryInto<U> for IterMut<'a, A> where U: TryFrom<T>,

type Error = <U as TryFrom<T>>::Error;
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>