Struct lens_rs_generator::_ix[][src]

pub struct _ix<I, Optic>(pub Optic, pub I);

behave as xs[index]

assert_eq!(vec![1,2,3].view_ref(optics!([1])), &2);
assert_eq!(vec![1,2,3].view_ref(optics!([1..])), &[2, 3]);

Trait Implementations

impl<I: Clone, Optic: Clone> Clone for _ix<I, Optic>[src]

impl<I: Copy, Optic: Copy> Copy for _ix<I, Optic>[src]

impl<I: Debug, Optic: Debug> Debug for _ix<I, Optic>[src]

impl<I: Eq, Optic: Eq> Eq for _ix<I, Optic>[src]

impl<I: PartialEq, Optic: PartialEq> PartialEq<_ix<I, Optic>> for _ix<I, Optic>[src]

impl<I, Optic> StructuralEq for _ix<I, Optic>[src]

impl<I, Optic> StructuralPartialEq for _ix<I, Optic>[src]

Auto Trait Implementations

impl<I, Optic> RefUnwindSafe for _ix<I, Optic> where
    I: RefUnwindSafe,
    Optic: RefUnwindSafe

impl<I, Optic> Send for _ix<I, Optic> where
    I: Send,
    Optic: Send

impl<I, Optic> Sync for _ix<I, Optic> where
    I: Sync,
    Optic: Sync

impl<I, Optic> Unpin for _ix<I, Optic> where
    I: Unpin,
    Optic: Unpin

impl<I, Optic> UnwindSafe for _ix<I, Optic> where
    I: UnwindSafe,
    Optic: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized

impl<T> Borrow<T> for T where
    T: ?Sized

impl<T> BorrowMut<T> for T where
    T: ?Sized

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 

impl<T> ToOwned for T where
    T: Clone

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.