pub struct Func {
pub id: usize,
pub bytecode: Option<Vec<u8>>,
}Expand description
An opaque Lua function.
id gives identity for shared-reference tracking. bytecode, when present,
is the string.dump output the serializer quotes into a reload stub.
Equality is by id. Two functions with the same identity are equal, matching
Lua reference semantics. The bytecode is not compared.
Fields§
§id: usizeIdentity of this function.
bytecode: Option<Vec<u8>>Optional dumped bytecode. None means the function cannot be dumped and
falls back to a global name or placeholder.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Func
impl RefUnwindSafe for Func
impl Send for Func
impl Sync for Func
impl Unpin for Func
impl UnsafeUnpin for Func
impl UnwindSafe for Func
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