Skip to main content

TupleRefSurrogate

Struct TupleRefSurrogate 

Source
pub struct TupleRefSurrogate<'a, T>
where T: TupleProject<'a>,
{ /* private fields */ }
Expand description

A borrowed tuple of runtime values.

Field access reads the borrowed elements, so .0 on a borrowed pair borrows its first element.

Implementations§

Source§

impl<'a, T> TupleRefSurrogate<'a, T>
where T: TupleProject<'a> + Surrogated + Clone,

Source

pub fn clone(&self) -> T::Surrogate

Clones the borrowed tuple into an owned tuple.

Trait Implementations§

Source§

impl<'a, T> Deref for TupleRefSurrogate<'a, T>
where T: TupleProject<'a>,

Source§

type Target = <T as TupleProject<'a>>::Projected

The resulting type after dereferencing.
Source§

fn deref(&self) -> &Self::Target

Dereferences the value.
Source§

impl<'a, T> Serialize for TupleRefSurrogate<'a, T>
where T: TupleProject<'a>, T::Projected: Serialize,

Source§

fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
where S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl<'a, T1: 'a> Surrogate for TupleRefSurrogate<'a, (T1,)>

Source§

type Real = &'a (T1,)

Source§

fn into_real(self) -> Self::Real

Source§

impl<'a, T1: 'a, T2: 'a> Surrogate for TupleRefSurrogate<'a, (T1, T2)>

Source§

type Real = &'a (T1, T2)

Source§

fn into_real(self) -> Self::Real

Source§

impl<'a, T1: 'a, T2: 'a, T3: 'a> Surrogate for TupleRefSurrogate<'a, (T1, T2, T3)>

Source§

type Real = &'a (T1, T2, T3)

Source§

fn into_real(self) -> Self::Real

Source§

impl<'a, T1: 'a, T2: 'a, T3: 'a, T4: 'a> Surrogate for TupleRefSurrogate<'a, (T1, T2, T3, T4)>

Source§

impl<'a, T1: 'a, T2: 'a, T3: 'a, T4: 'a, T5: 'a> Surrogate for TupleRefSurrogate<'a, (T1, T2, T3, T4, T5)>

Source§

impl<'a, T1: 'a, T2: 'a, T3: 'a, T4: 'a, T5: 'a, T6: 'a> Surrogate for TupleRefSurrogate<'a, (T1, T2, T3, T4, T5, T6)>

Source§

impl<'a, T1: 'a, T2: 'a, T3: 'a, T4: 'a, T5: 'a, T6: 'a, T7: 'a> Surrogate for TupleRefSurrogate<'a, (T1, T2, T3, T4, T5, T6, T7)>

Source§

impl<'a, T1: 'a, T2: 'a, T3: 'a, T4: 'a, T5: 'a, T6: 'a, T7: 'a, T8: 'a> Surrogate for TupleRefSurrogate<'a, (T1, T2, T3, T4, T5, T6, T7, T8)>

Source§

impl<'a, T1: 'a, T2: 'a, T3: 'a, T4: 'a, T5: 'a, T6: 'a, T7: 'a, T8: 'a, T9: 'a> Surrogate for TupleRefSurrogate<'a, (T1, T2, T3, T4, T5, T6, T7, T8, T9)>

Source§

impl<'a, T1: 'a, T2: 'a, T3: 'a, T4: 'a, T5: 'a, T6: 'a, T7: 'a, T8: 'a, T9: 'a, T10: 'a> Surrogate for TupleRefSurrogate<'a, (T1, T2, T3, T4, T5, T6, T7, T8, T9, T10)>

Source§

impl<'a, T1: 'a, T2: 'a, T3: 'a, T4: 'a, T5: 'a, T6: 'a, T7: 'a, T8: 'a, T9: 'a, T10: 'a, T11: 'a> Surrogate for TupleRefSurrogate<'a, (T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11)>

Source§

impl<'a, T1: 'a, T2: 'a, T3: 'a, T4: 'a, T5: 'a, T6: 'a, T7: 'a, T8: 'a, T9: 'a, T10: 'a, T11: 'a, T12: 'a> Surrogate for TupleRefSurrogate<'a, (T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12)>

Auto Trait Implementations§

§

impl<'a, T> Freeze for TupleRefSurrogate<'a, T>
where &'a T: Freeze, <T as TupleProject<'a>>::Projected: Freeze,

§

impl<'a, T> RefUnwindSafe for TupleRefSurrogate<'a, T>

§

impl<'a, T> Send for TupleRefSurrogate<'a, T>
where &'a T: Send, <T as TupleProject<'a>>::Projected: Send,

§

impl<'a, T> Sync for TupleRefSurrogate<'a, T>
where &'a T: Sync, <T as TupleProject<'a>>::Projected: Sync,

§

impl<'a, T> Unpin for TupleRefSurrogate<'a, T>
where &'a T: Unpin, <T as TupleProject<'a>>::Projected: Unpin,

§

impl<'a, T> UnsafeUnpin for TupleRefSurrogate<'a, T>

§

impl<'a, T> UnwindSafe for TupleRefSurrogate<'a, T>

Blanket Implementations§

Source§

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

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

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

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

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

Source§

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

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self> ⓘ

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self> ⓘ

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

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

Source§

fn into(self) -> U

Calls U::from(self).

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

Source§

impl<P, T> Receiver for P
where P: Deref<Target = T> + ?Sized, T: ?Sized,

Source§

type Target = T

🔬This is a nightly-only experimental API. (arbitrary_self_types)
The target type on which the method may be called.
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

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

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

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

Source§

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

The type returned in the event of a conversion error.
Source§

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

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘ
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more