pub struct BlockCnt {
pub previous: Option<Box<BlockCnt>>,
pub firstlabel: i32,
pub firstgoto: i32,
pub nactvar: u8,
pub upval: bool,
pub isloop: bool,
pub insidetbc: bool,
pub saved_global_strict: bool,
pub saved_declared_globals: usize,
}Expand description
In C: stack-allocated, chained via raw *previous pointer.
In Rust: heap-allocated in an Option<Box<BlockCnt>> chain on FuncState.
Fields§
§previous: Option<Box<BlockCnt>>§firstlabel: i32§firstgoto: i32§nactvar: u8§upval: bool§isloop: bool§insidetbc: bool§saved_global_strict: boolLua 5.5: the global-declaration scope state (LexState global_strict
and the length of declared_globals) saved on block entry and restored
on exit, so a global declaration is scoped to its enclosing block —
e.g. do global x end does not leak strict mode past the block.
saved_declared_globals: usizeTrait Implementations§
Auto Trait Implementations§
impl Freeze for BlockCnt
impl RefUnwindSafe for BlockCnt
impl Send for BlockCnt
impl Sync for BlockCnt
impl Unpin for BlockCnt
impl UnsafeUnpin for BlockCnt
impl UnwindSafe for BlockCnt
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