pub struct UpvalDesc {
pub in_stack: bool,
pub index: u8,
pub name: Box<str>,
pub read_only: bool,
}Expand description
Where a closure’s upvalue is captured from, relative to the enclosing function (PUC Upvaldesc).
Fields§
§in_stack: boolcaptured from the enclosing frame’s registers (true) or from the enclosing closure’s own upvalues (false)
index: u8Index in the enclosing frame’s register file (when in_stack) or
in the enclosing closure’s upvalue array (otherwise).
name: Box<str>variable name, for error messages and debug info
read_only: boolthe captured variable is <const> (5.5): assignment through this
upvalue is a compile-time error
Trait Implementations§
Auto Trait Implementations§
impl Freeze for UpvalDesc
impl RefUnwindSafe for UpvalDesc
impl Send for UpvalDesc
impl Sync for UpvalDesc
impl Unpin for UpvalDesc
impl UnsafeUnpin for UpvalDesc
impl UnwindSafe for UpvalDesc
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