pub struct FrameState {
protected_tags: SmallVec<[(AllocId, BorTag); 2]>,
}
Expand description
Per-call-stack-frame data for borrow tracking
Fields§
If this frame is protecting any tags, they are listed here. We use this list to do
incremental updates of the global list of protected tags stored in the
stacked_borrows::GlobalState
upon function return, and if we attempt to pop a protected
tag, to identify which call is responsible for protecting the tag.
See Stack::item_invalidated
for more explanation.
Tree Borrows also needs to know which allocation these tags
belong to so that it can perform a read through them immediately before
the frame gets popped.
This will contain one tag per reference passed to the function, so a size of 2 is enough for the vast majority of functions.
Trait Implementations§
Source§impl Debug for FrameState
impl Debug for FrameState
Source§impl VisitProvenance for FrameState
impl VisitProvenance for FrameState
fn visit_provenance(&self, visit: &mut VisitWith<'_>)
Auto Trait Implementations§
impl Freeze for FrameState
impl RefUnwindSafe for FrameState
impl Send for FrameState
impl Sync for FrameState
impl Unpin for FrameState
impl UnwindSafe for FrameState
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
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 48 bytes