pub trait ForLifetimeTable {
type WithLt<'lt>: ForLifetimeTable + Table + Sized;
// Required methods
fn with_lt<'lt>(self, marker: &mut WithLtMarker) -> Self::WithLt<'lt>;
fn unwith_lt<'lt>(
with_lt: Self::WithLt<'lt>,
marker: &mut WithLtMarker,
) -> Self;
}Expand description
A helper trait that allows us to talk about a Table with different
lifetimes. Conceptually it is a type level function of lt -> T where T: Table.
If you implement Table on your type, you must also implement ForLifetimeTable.
Required Associated Types§
Sourcetype WithLt<'lt>: ForLifetimeTable + Table + Sized
type WithLt<'lt>: ForLifetimeTable + Table + Sized
Substitute the lifetime of this table with 'lt.
Required Methods§
Sourcefn with_lt<'lt>(self, marker: &mut WithLtMarker) -> Self::WithLt<'lt>
fn with_lt<'lt>(self, marker: &mut WithLtMarker) -> Self::WithLt<'lt>
Coerce the lifetime of this table. This is used internally by the library.
fn unwith_lt<'lt>(with_lt: Self::WithLt<'lt>, marker: &mut WithLtMarker) -> Self
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementations on Foreign Types§
Source§impl<T> ForLifetimeTable for (T₁, T₂, …, Tₙ)where
T: ForLifetimeTable,
This trait is implemented for tuples up to 15 items long.
impl<T> ForLifetimeTable for (T₁, T₂, …, Tₙ)where
T: ForLifetimeTable,
This trait is implemented for tuples up to 15 items long.