pub struct ContextCache<T> { /* private fields */ }Expand description
Thread-local context cache with fast path for single Fory instance. Uses (cached_id, context) for O(1) access when using same Fory instance repeatedly. Falls back to HashMap for multiple Fory instances per thread.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl<T> Freeze for ContextCache<T>
impl<T> RefUnwindSafe for ContextCache<T>where
T: RefUnwindSafe,
impl<T> Send for ContextCache<T>where
T: Send,
impl<T> Sync for ContextCache<T>where
T: Sync,
impl<T> Unpin for ContextCache<T>
impl<T> UnwindSafe for ContextCache<T>where
T: UnwindSafe,
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