pub struct LuaThread {
pub local_variables: Vec<RefOrValue>,
pub bp: usize,
pub data_stack: Vec<LuaValue>,
pub usize_stack: Vec<usize>,
pub call_stack: Vec<CallStackFrame>,
pub status: ThreadStatus,
pub function: Option<Rc<RefCell<LuaFunction>>>,
}
Expand description
Type for Lua thread.
Fields§
§local_variables: Vec<RefOrValue>
local variable stack
bp: usize
offset of local variables for current scope
data_stack: Vec<LuaValue>
normal stack, for temporary values
usize_stack: Vec<usize>
stack for storing usize values
call_stack: Vec<CallStackFrame>
§status: ThreadStatus
§function: Option<Rc<RefCell<LuaFunction>>>
If this thread is created by coroutine.create
, this field is Some.
The function object of the coroutine.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for LuaThread
impl !RefUnwindSafe for LuaThread
impl !Send for LuaThread
impl !Sync for LuaThread
impl Unpin for LuaThread
impl !UnwindSafe for LuaThread
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