Struct inline_dyn::InlineDyn [−][src]
A container type that stores a dynamically-sized type (e.g., a trait object) inline within the container.
The S
and A
generic parameters specify the size and alignment (in bytes) of the internal
storage.
Examples
use inline_dyn::fmt::InlineDynDebug; let val: InlineDynDebug = InlineDynDebug::try_new(42u8).unwrap(); assert_eq!(format!("{:?}", val), "42");
Implementations
impl<'a, D, S, A> InlineDyn<'a, D, S, A> where
D: ?Sized,
S: Size,
A: Align,
[src]
D: ?Sized,
S: Size,
A: Align,
pub fn try_new<T>(value: T) -> Result<Self, T> where
T: Unsize<D> + 'a,
[src]
T: Unsize<D> + 'a,
nightly
only.Attempt to construct a new InlineDyn
containing the given value.
The size and alignment of the internal storage must be large enough to store the given value, otherwise the value is returned.
Note: if not using the nightly feature, this method is only implemented for certain
values of D
. The inline_dyn!
macro can be used as alternative on stable.
pub fn try_or_box<T>(value: T) -> Self where
T: Unsize<D> + 'a,
Box<T>: Unsize<D> + 'a,
S: IsGreaterOrEqual<DefaultSize>,
A: IsGreaterOrEqual<DefaultSize>,
[src]
T: Unsize<D> + 'a,
Box<T>: Unsize<D> + 'a,
S: IsGreaterOrEqual<DefaultSize>,
A: IsGreaterOrEqual<DefaultSize>,
nightly
and alloc
only.Construct a new InlineDyn
containing the given value if the value can fit in the internal
storage, or else box the value and store that.
Note: if not using the nightly feature, this method is only implemented for certain
values of D
. The inline_dyn_box!
macro can be used as alternative on stable.
Examples
use core::mem; use inline_dyn::fmt::InlineDynDebug; #[derive(Debug)] struct LargerThanBox([usize; 5]); let val: InlineDynDebug = InlineDynDebug::try_or_box(LargerThanBox([1, 2, 3, 4, 5])); assert!(mem::size_of_val(val.get_ref()) < mem::size_of::<LargerThanBox>()); assert_eq!(format!("{:?}", val.get_ref()), "LargerThanBox([1, 2, 3, 4, 5])");
impl<D: ?Sized, S, A> InlineDyn<'static, D, S, A> where
D: Any,
S: Size,
A: Align,
[src]
D: Any,
S: Size,
A: Align,
impl<'a, D: ?Sized, S: Size, A: Align> InlineDyn<'a, D, S, A>
[src]
pub fn get_ref(&self) -> &D
[src]
Returns a shared reference to the stored value.
pub fn get_mut(&mut self) -> &mut D
[src]
Returns a mutable reference to the stored value.
pub fn grow<U, V>(this: Self) -> InlineDyn<'a, D, U, V>ⓘNotable traits for InlineDyn<'_, I, S, A>
impl<I: ?Sized, S, A> Iterator for InlineDyn<'_, I, S, A> where
I: Iterator,
S: Size,
A: Align, type Item = I::Item;impl<T: ?Sized, S, A> Read for InlineDyn<'_, T, S, A> where
T: Read,
S: Size,
A: Align, impl<T: ?Sized, S, A> Write for InlineDyn<'_, T, S, A> where
T: Write,
S: Size,
A: Align, impl<F: ?Sized, S, A> Future for InlineDyn<'_, F, S, A> where
F: Future + Unpin,
S: Size,
A: Align, type Output = F::Output;
where
U: Size + IsGreaterOrEqual<S>,
V: Align + IsGreaterOrEqual<A>,
[src]
Notable traits for InlineDyn<'_, I, S, A>
impl<I: ?Sized, S, A> Iterator for InlineDyn<'_, I, S, A> where
I: Iterator,
S: Size,
A: Align, type Item = I::Item;impl<T: ?Sized, S, A> Read for InlineDyn<'_, T, S, A> where
T: Read,
S: Size,
A: Align, impl<T: ?Sized, S, A> Write for InlineDyn<'_, T, S, A> where
T: Write,
S: Size,
A: Align, impl<F: ?Sized, S, A> Future for InlineDyn<'_, F, S, A> where
F: Future + Unpin,
S: Size,
A: Align, type Output = F::Output;
U: Size + IsGreaterOrEqual<S>,
V: Align + IsGreaterOrEqual<A>,
Creates a new InlineDyn
with a larger internal storage containing the value stored in
this
.
pub fn try_resize<U, V>(this: Self) -> Result<InlineDyn<'a, D, U, V>, Self> where
U: Size,
V: Align,
[src]
U: Size,
V: Align,
Attempts to create a new InlineDyn
with the given size and alignment for the internal
storage containing the value stored in this
.
The size and alignment must be large enough to store the contained value, otherwise this
is returned.
Trait Implementations
impl<T: ?Sized, S, A> BufRead for InlineDyn<'_, T, S, A> where
T: BufRead,
S: Size,
A: Align,
[src]
T: BufRead,
S: Size,
A: Align,
std
only.fn fill_buf(&mut self) -> Result<&[u8]>
[src]
fn consume(&mut self, amt: usize)
[src]
pub fn read_until(
&mut self,
byte: u8,
buf: &mut Vec<u8, Global>
) -> Result<usize, Error>
1.0.0[src]
&mut self,
byte: u8,
buf: &mut Vec<u8, Global>
) -> Result<usize, Error>
pub fn read_line(&mut self, buf: &mut String) -> Result<usize, Error>
1.0.0[src]
pub fn split(self, byte: u8) -> Split<Self>
1.0.0[src]
pub fn lines(self) -> Lines<Self>
1.0.0[src]
impl<D: Debug + ?Sized, S: Size, A: Align> Debug for InlineDyn<'_, D, S, A>
[src]
impl<D: ?Sized, S: Size, A: Align> Deref for InlineDyn<'_, D, S, A>
[src]
impl<D: ?Sized, S: Size, A: Align> DerefMut for InlineDyn<'_, D, S, A>
[src]
impl<D: Display + ?Sized, S: Size, A: Align> Display for InlineDyn<'_, D, S, A>
[src]
impl<I: ?Sized, S, A> DoubleEndedIterator for InlineDyn<'_, I, S, A> where
I: DoubleEndedIterator,
S: Size,
A: Align,
[src]
I: DoubleEndedIterator,
S: Size,
A: Align,
fn next_back(&mut self) -> Option<Self::Item>
[src]
fn nth_back(&mut self, n: usize) -> Option<Self::Item>
[src]
pub fn advance_back_by(&mut self, n: usize) -> Result<(), usize>
[src]
pub fn try_rfold<B, F, R>(&mut self, init: B, f: F) -> R where
F: FnMut(B, Self::Item) -> R,
R: Try<Ok = B>,
1.27.0[src]
F: FnMut(B, Self::Item) -> R,
R: Try<Ok = B>,
pub fn rfold<B, F>(self, init: B, f: F) -> B where
F: FnMut(B, Self::Item) -> B,
1.27.0[src]
F: FnMut(B, Self::Item) -> B,
pub fn rfind<P>(&mut self, predicate: P) -> Option<Self::Item> where
P: FnMut(&Self::Item) -> bool,
1.27.0[src]
P: FnMut(&Self::Item) -> bool,
impl<D: ?Sized, S: Size, A: Align> Drop for InlineDyn<'_, D, S, A>
[src]
impl<E: ?Sized, S, A> Error for InlineDyn<'_, E, S, A> where
E: Error,
S: Size,
A: Align,
[src]
E: Error,
S: Size,
A: Align,
std
only.fn description(&self) -> &str
[src]
fn cause(&self) -> Option<&dyn Error>
[src]
fn source(&self) -> Option<&(dyn Error + 'static)>
[src]
pub fn backtrace(&self) -> Option<&Backtrace>
[src]
impl<I: ?Sized, S, A> ExactSizeIterator for InlineDyn<'_, I, S, A> where
I: ExactSizeIterator,
S: Size,
A: Align,
[src]
I: ExactSizeIterator,
S: Size,
A: Align,
impl<I: ?Sized, S, A> FusedIterator for InlineDyn<'_, I, S, A> where
I: FusedIterator,
S: Size,
A: Align,
[src]
I: FusedIterator,
S: Size,
A: Align,
impl<F: ?Sized, S, A> Future for InlineDyn<'_, F, S, A> where
F: Future + Unpin,
S: Size,
A: Align,
[src]
F: Future + Unpin,
S: Size,
A: Align,
type Output = F::Output
The type of value produced on completion.
fn poll(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Self::Output>
[src]
impl<I: ?Sized, S, A> Iterator for InlineDyn<'_, I, S, A> where
I: Iterator,
S: Size,
A: Align,
[src]
I: Iterator,
S: Size,
A: Align,
type Item = I::Item
The type of the elements being iterated over.
fn next(&mut self) -> Option<Self::Item>
[src]
fn size_hint(&self) -> (usize, Option<usize>)
[src]
fn nth(&mut self, n: usize) -> Option<Self::Item>
[src]
pub fn count(self) -> usize
1.0.0[src]
pub fn last(self) -> Option<Self::Item>
1.0.0[src]
pub fn advance_by(&mut self, n: usize) -> Result<(), usize>
[src]
pub fn step_by(self, step: usize) -> StepBy<Self>
1.28.0[src]
pub fn chain<U>(self, other: U) -> Chain<Self, <U as IntoIterator>::IntoIter> where
U: IntoIterator<Item = Self::Item>,
1.0.0[src]
U: IntoIterator<Item = Self::Item>,
pub fn zip<U>(self, other: U) -> Zip<Self, <U as IntoIterator>::IntoIter> where
U: IntoIterator,
1.0.0[src]
U: IntoIterator,
pub fn intersperse(self, separator: Self::Item) -> Intersperse<Self> where
Self::Item: Clone,
[src]
Self::Item: Clone,
pub fn intersperse_with<G>(self, separator: G) -> IntersperseWith<Self, G> where
G: FnMut() -> Self::Item,
[src]
G: FnMut() -> Self::Item,
pub fn map<B, F>(self, f: F) -> Map<Self, F> where
F: FnMut(Self::Item) -> B,
1.0.0[src]
F: FnMut(Self::Item) -> B,
pub fn for_each<F>(self, f: F) where
F: FnMut(Self::Item),
1.21.0[src]
F: FnMut(Self::Item),
pub fn filter<P>(self, predicate: P) -> Filter<Self, P> where
P: FnMut(&Self::Item) -> bool,
1.0.0[src]
P: FnMut(&Self::Item) -> bool,
pub fn filter_map<B, F>(self, f: F) -> FilterMap<Self, F> where
F: FnMut(Self::Item) -> Option<B>,
1.0.0[src]
F: FnMut(Self::Item) -> Option<B>,
pub fn enumerate(self) -> Enumerate<Self>
1.0.0[src]
pub fn peekable(self) -> Peekable<Self>
1.0.0[src]
pub fn skip_while<P>(self, predicate: P) -> SkipWhile<Self, P> where
P: FnMut(&Self::Item) -> bool,
1.0.0[src]
P: FnMut(&Self::Item) -> bool,
pub fn take_while<P>(self, predicate: P) -> TakeWhile<Self, P> where
P: FnMut(&Self::Item) -> bool,
1.0.0[src]
P: FnMut(&Self::Item) -> bool,
pub fn map_while<B, P>(self, predicate: P) -> MapWhile<Self, P> where
P: FnMut(Self::Item) -> Option<B>,
[src]
P: FnMut(Self::Item) -> Option<B>,
pub fn skip(self, n: usize) -> Skip<Self>
1.0.0[src]
pub fn take(self, n: usize) -> Take<Self>
1.0.0[src]
pub fn scan<St, B, F>(self, initial_state: St, f: F) -> Scan<Self, St, F> where
F: FnMut(&mut St, Self::Item) -> Option<B>,
1.0.0[src]
F: FnMut(&mut St, Self::Item) -> Option<B>,
pub fn flat_map<U, F>(self, f: F) -> FlatMap<Self, U, F> where
U: IntoIterator,
F: FnMut(Self::Item) -> U,
1.0.0[src]
U: IntoIterator,
F: FnMut(Self::Item) -> U,
pub fn flatten(self) -> Flatten<Self> where
Self::Item: IntoIterator,
1.29.0[src]
Self::Item: IntoIterator,
pub fn fuse(self) -> Fuse<Self>
1.0.0[src]
pub fn inspect<F>(self, f: F) -> Inspect<Self, F> where
F: FnMut(&Self::Item),
1.0.0[src]
F: FnMut(&Self::Item),
pub fn by_ref(&mut self) -> &mut Self
1.0.0[src]
#[must_use =
"if you really need to exhaust the iterator, consider `.for_each(drop)` instead"]pub fn collect<B>(self) -> B where
B: FromIterator<Self::Item>,
1.0.0[src]
B: FromIterator<Self::Item>,
pub fn partition<B, F>(self, f: F) -> (B, B) where
F: FnMut(&Self::Item) -> bool,
B: Default + Extend<Self::Item>,
1.0.0[src]
F: FnMut(&Self::Item) -> bool,
B: Default + Extend<Self::Item>,
pub fn partition_in_place<'a, T, P>(self, predicate: P) -> usize where
Self: DoubleEndedIterator<Item = &'a mut T>,
T: 'a,
P: FnMut(&T) -> bool,
[src]
Self: DoubleEndedIterator<Item = &'a mut T>,
T: 'a,
P: FnMut(&T) -> bool,
pub fn is_partitioned<P>(self, predicate: P) -> bool where
P: FnMut(Self::Item) -> bool,
[src]
P: FnMut(Self::Item) -> bool,
pub fn try_fold<B, F, R>(&mut self, init: B, f: F) -> R where
F: FnMut(B, Self::Item) -> R,
R: Try<Ok = B>,
1.27.0[src]
F: FnMut(B, Self::Item) -> R,
R: Try<Ok = B>,
pub fn try_for_each<F, R>(&mut self, f: F) -> R where
F: FnMut(Self::Item) -> R,
R: Try<Ok = ()>,
1.27.0[src]
F: FnMut(Self::Item) -> R,
R: Try<Ok = ()>,
pub fn fold<B, F>(self, init: B, f: F) -> B where
F: FnMut(B, Self::Item) -> B,
1.0.0[src]
F: FnMut(B, Self::Item) -> B,
pub fn reduce<F>(self, f: F) -> Option<Self::Item> where
F: FnMut(Self::Item, Self::Item) -> Self::Item,
1.51.0[src]
F: FnMut(Self::Item, Self::Item) -> Self::Item,
pub fn all<F>(&mut self, f: F) -> bool where
F: FnMut(Self::Item) -> bool,
1.0.0[src]
F: FnMut(Self::Item) -> bool,
pub fn any<F>(&mut self, f: F) -> bool where
F: FnMut(Self::Item) -> bool,
1.0.0[src]
F: FnMut(Self::Item) -> bool,
pub fn find<P>(&mut self, predicate: P) -> Option<Self::Item> where
P: FnMut(&Self::Item) -> bool,
1.0.0[src]
P: FnMut(&Self::Item) -> bool,
pub fn find_map<B, F>(&mut self, f: F) -> Option<B> where
F: FnMut(Self::Item) -> Option<B>,
1.30.0[src]
F: FnMut(Self::Item) -> Option<B>,
pub fn try_find<F, R>(
&mut self,
f: F
) -> Result<Option<Self::Item>, <R as Try>::Error> where
F: FnMut(&Self::Item) -> R,
R: Try<Ok = bool>,
[src]
&mut self,
f: F
) -> Result<Option<Self::Item>, <R as Try>::Error> where
F: FnMut(&Self::Item) -> R,
R: Try<Ok = bool>,
pub fn position<P>(&mut self, predicate: P) -> Option<usize> where
P: FnMut(Self::Item) -> bool,
1.0.0[src]
P: FnMut(Self::Item) -> bool,
pub fn rposition<P>(&mut self, predicate: P) -> Option<usize> where
Self: ExactSizeIterator + DoubleEndedIterator,
P: FnMut(Self::Item) -> bool,
1.0.0[src]
Self: ExactSizeIterator + DoubleEndedIterator,
P: FnMut(Self::Item) -> bool,
pub fn max(self) -> Option<Self::Item> where
Self::Item: Ord,
1.0.0[src]
Self::Item: Ord,
pub fn min(self) -> Option<Self::Item> where
Self::Item: Ord,
1.0.0[src]
Self::Item: Ord,
pub fn max_by_key<B, F>(self, f: F) -> Option<Self::Item> where
F: FnMut(&Self::Item) -> B,
B: Ord,
1.6.0[src]
F: FnMut(&Self::Item) -> B,
B: Ord,
pub fn max_by<F>(self, compare: F) -> Option<Self::Item> where
F: FnMut(&Self::Item, &Self::Item) -> Ordering,
1.15.0[src]
F: FnMut(&Self::Item, &Self::Item) -> Ordering,
pub fn min_by_key<B, F>(self, f: F) -> Option<Self::Item> where
F: FnMut(&Self::Item) -> B,
B: Ord,
1.6.0[src]
F: FnMut(&Self::Item) -> B,
B: Ord,
pub fn min_by<F>(self, compare: F) -> Option<Self::Item> where
F: FnMut(&Self::Item, &Self::Item) -> Ordering,
1.15.0[src]
F: FnMut(&Self::Item, &Self::Item) -> Ordering,
pub fn rev(self) -> Rev<Self> where
Self: DoubleEndedIterator,
1.0.0[src]
Self: DoubleEndedIterator,
pub fn unzip<A, B, FromA, FromB>(self) -> (FromA, FromB) where
Self: Iterator<Item = (A, B)>,
FromA: Default + Extend<A>,
FromB: Default + Extend<B>,
1.0.0[src]
Self: Iterator<Item = (A, B)>,
FromA: Default + Extend<A>,
FromB: Default + Extend<B>,
pub fn copied<'a, T>(self) -> Copied<Self> where
Self: Iterator<Item = &'a T>,
T: 'a + Copy,
1.36.0[src]
Self: Iterator<Item = &'a T>,
T: 'a + Copy,
pub fn cloned<'a, T>(self) -> Cloned<Self> where
Self: Iterator<Item = &'a T>,
T: 'a + Clone,
1.0.0[src]
Self: Iterator<Item = &'a T>,
T: 'a + Clone,
pub fn cycle(self) -> Cycle<Self> where
Self: Clone,
1.0.0[src]
Self: Clone,
pub fn sum<S>(self) -> S where
S: Sum<Self::Item>,
1.11.0[src]
S: Sum<Self::Item>,
pub fn product<P>(self) -> P where
P: Product<Self::Item>,
1.11.0[src]
P: Product<Self::Item>,
pub fn cmp<I>(self, other: I) -> Ordering where
I: IntoIterator<Item = Self::Item>,
Self::Item: Ord,
1.5.0[src]
I: IntoIterator<Item = Self::Item>,
Self::Item: Ord,
pub fn cmp_by<I, F>(self, other: I, cmp: F) -> Ordering where
F: FnMut(Self::Item, <I as IntoIterator>::Item) -> Ordering,
I: IntoIterator,
[src]
F: FnMut(Self::Item, <I as IntoIterator>::Item) -> Ordering,
I: IntoIterator,
pub fn partial_cmp<I>(self, other: I) -> Option<Ordering> where
I: IntoIterator,
Self::Item: PartialOrd<<I as IntoIterator>::Item>,
1.5.0[src]
I: IntoIterator,
Self::Item: PartialOrd<<I as IntoIterator>::Item>,
pub fn partial_cmp_by<I, F>(self, other: I, partial_cmp: F) -> Option<Ordering> where
F: FnMut(Self::Item, <I as IntoIterator>::Item) -> Option<Ordering>,
I: IntoIterator,
[src]
F: FnMut(Self::Item, <I as IntoIterator>::Item) -> Option<Ordering>,
I: IntoIterator,
pub fn eq<I>(self, other: I) -> bool where
I: IntoIterator,
Self::Item: PartialEq<<I as IntoIterator>::Item>,
1.5.0[src]
I: IntoIterator,
Self::Item: PartialEq<<I as IntoIterator>::Item>,
pub fn eq_by<I, F>(self, other: I, eq: F) -> bool where
F: FnMut(Self::Item, <I as IntoIterator>::Item) -> bool,
I: IntoIterator,
[src]
F: FnMut(Self::Item, <I as IntoIterator>::Item) -> bool,
I: IntoIterator,
pub fn ne<I>(self, other: I) -> bool where
I: IntoIterator,
Self::Item: PartialEq<<I as IntoIterator>::Item>,
1.5.0[src]
I: IntoIterator,
Self::Item: PartialEq<<I as IntoIterator>::Item>,
pub fn lt<I>(self, other: I) -> bool where
I: IntoIterator,
Self::Item: PartialOrd<<I as IntoIterator>::Item>,
1.5.0[src]
I: IntoIterator,
Self::Item: PartialOrd<<I as IntoIterator>::Item>,
pub fn le<I>(self, other: I) -> bool where
I: IntoIterator,
Self::Item: PartialOrd<<I as IntoIterator>::Item>,
1.5.0[src]
I: IntoIterator,
Self::Item: PartialOrd<<I as IntoIterator>::Item>,
pub fn gt<I>(self, other: I) -> bool where
I: IntoIterator,
Self::Item: PartialOrd<<I as IntoIterator>::Item>,
1.5.0[src]
I: IntoIterator,
Self::Item: PartialOrd<<I as IntoIterator>::Item>,
pub fn ge<I>(self, other: I) -> bool where
I: IntoIterator,
Self::Item: PartialOrd<<I as IntoIterator>::Item>,
1.5.0[src]
I: IntoIterator,
Self::Item: PartialOrd<<I as IntoIterator>::Item>,
pub fn is_sorted(self) -> bool where
Self::Item: PartialOrd<Self::Item>,
[src]
Self::Item: PartialOrd<Self::Item>,
pub fn is_sorted_by<F>(self, compare: F) -> bool where
F: FnMut(&Self::Item, &Self::Item) -> Option<Ordering>,
[src]
F: FnMut(&Self::Item, &Self::Item) -> Option<Ordering>,
pub fn is_sorted_by_key<F, K>(self, f: F) -> bool where
F: FnMut(Self::Item) -> K,
K: PartialOrd<K>,
[src]
F: FnMut(Self::Item) -> K,
K: PartialOrd<K>,
impl<T: ?Sized, S, A> Read for InlineDyn<'_, T, S, A> where
T: Read,
S: Size,
A: Align,
[src]
T: Read,
S: Size,
A: Align,
std
only.fn read(&mut self, buf: &mut [u8]) -> Result<usize>
[src]
fn read_vectored(&mut self, bufs: &mut [IoSliceMut<'_>]) -> Result<usize>
[src]
fn read_exact(&mut self, buf: &mut [u8]) -> Result<()>
[src]
pub fn is_read_vectored(&self) -> bool
[src]
pub unsafe fn initializer(&self) -> Initializer
[src]
pub fn read_to_end(&mut self, buf: &mut Vec<u8, Global>) -> Result<usize, Error>
1.0.0[src]
pub fn read_to_string(&mut self, buf: &mut String) -> Result<usize, Error>
1.0.0[src]
pub fn by_ref(&mut self) -> &mut Self
1.0.0[src]
pub fn bytes(self) -> Bytes<Self>
1.0.0[src]
pub fn chain<R>(self, next: R) -> Chain<Self, R> where
R: Read,
1.0.0[src]
R: Read,
pub fn take(self, limit: u64) -> Take<Self>
1.0.0[src]
impl<T: ?Sized, S, A> Seek for InlineDyn<'_, T, S, A> where
T: Seek,
S: Size,
A: Align,
[src]
T: Seek,
S: Size,
A: Align,
std
only.fn seek(&mut self, pos: SeekFrom) -> Result<u64>
[src]
pub fn stream_len(&mut self) -> Result<u64, Error>
[src]
pub fn stream_position(&mut self) -> Result<u64, Error>
1.51.0[src]
impl<T: ?Sized, S, A> Write for InlineDyn<'_, T, S, A> where
T: Write,
S: Size,
A: Align,
[src]
T: Write,
S: Size,
A: Align,
std
only.fn write(&mut self, buf: &[u8]) -> Result<usize>
[src]
fn write_vectored(&mut self, bufs: &[IoSlice<'_>]) -> Result<usize>
[src]
fn write_all(&mut self, buf: &[u8]) -> Result<()>
[src]
fn flush(&mut self) -> Result<()>
[src]
pub fn is_write_vectored(&self) -> bool
[src]
pub fn write_all_vectored(
&mut self,
bufs: &mut [IoSlice<'_>]
) -> Result<(), Error>
[src]
&mut self,
bufs: &mut [IoSlice<'_>]
) -> Result<(), Error>
pub fn write_fmt(&mut self, fmt: Arguments<'_>) -> Result<(), Error>
1.0.0[src]
pub fn by_ref(&mut self) -> &mut Self
1.0.0[src]
Auto Trait Implementations
impl<'a, D: ?Sized, S, A> RefUnwindSafe for InlineDyn<'a, D, S, A> where
D: RefUnwindSafe,
<A as Align>::Output: RefUnwindSafe,
<S as Size>::Output: RefUnwindSafe,
[src]
D: RefUnwindSafe,
<A as Align>::Output: RefUnwindSafe,
<S as Size>::Output: RefUnwindSafe,
impl<'a, D: ?Sized, S, A> Send for InlineDyn<'a, D, S, A> where
D: Send,
[src]
D: Send,
impl<'a, D: ?Sized, S, A> Sync for InlineDyn<'a, D, S, A> where
D: Sync,
[src]
D: Sync,
impl<'a, D: ?Sized, S, A> Unpin for InlineDyn<'a, D, S, A> where
D: Unpin,
[src]
D: Unpin,
impl<'a, D: ?Sized, S, A> UnwindSafe for InlineDyn<'a, D, S, A> where
D: UnwindSafe,
<A as Align>::Output: UnwindSafe,
<S as Size>::Output: UnwindSafe,
[src]
D: UnwindSafe,
<A as Align>::Output: UnwindSafe,
<S as Size>::Output: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<F> IntoFuture for F where
F: Future,
[src]
F: Future,
type Output = <F as Future>::Output
into_future
)The output that the future will produce on completion.
type Future = F
into_future
)Which kind of future are we turning this into?
pub fn into_future(self) -> <F as IntoFuture>::Future
[src]
impl<I> IntoIterator for I where
I: Iterator,
[src]
I: Iterator,
type Item = <I as Iterator>::Item
The type of the elements being iterated over.
type IntoIter = I
Which kind of iterator are we turning this into?
pub fn into_iter(self) -> I
[src]
impl<T> Same<T> for T
[src]
type Output = T
Should always be Self
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,