pub(super) struct DerivedCache {
generation: u64,
current: FxHashMap<TypeId, Arc<dyn Any + Send + Sync>>,
prev: FxHashMap<TypeId, Arc<dyn Any + Send + Sync>>,
}Expand description
The previous generation’s values stick around (prev) so incremental
builders can extend them instead of starting over; a value is consumed
(removed) the first time its type resolves under the new generation, and
anything never consumed drops on the following generation change.
Fields§
§generation: u64§current: FxHashMap<TypeId, Arc<dyn Any + Send + Sync>>§prev: FxHashMap<TypeId, Arc<dyn Any + Send + Sync>>Auto Trait Implementations§
impl Freeze for DerivedCache
impl !RefUnwindSafe for DerivedCache
impl Send for DerivedCache
impl Sync for DerivedCache
impl Unpin for DerivedCache
impl UnsafeUnpin for DerivedCache
impl !UnwindSafe for DerivedCache
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more