pub struct Function { /* private fields */ }Expand description
An explicit function record: metadata, code, and handlers. On entry the
leading capture_count registers hold the closure’s captured cells and the
next parameter_count registers hold the parameters; all capture_count + parameter_count are initialized on entry.
Implementations§
Source§impl Function
impl Function
pub fn new( name: Option<ConstantId>, capture_count: u32, parameter_count: u32, register_count: u32, flags: FunctionFlags, code: Vec<Instruction>, handlers: Vec<ExceptionHandler>, ) -> Self
pub const fn name(&self) -> Option<ConstantId>
pub const fn capture_count(&self) -> u32
pub const fn parameter_count(&self) -> u32
pub const fn register_count(&self) -> u32
pub const fn flags(&self) -> FunctionFlags
pub fn code(&self) -> &[Instruction]
pub fn handlers(&self) -> &[ExceptionHandler]
Trait Implementations§
impl Eq for Function
impl StructuralPartialEq for Function
Auto Trait Implementations§
impl Freeze for Function
impl RefUnwindSafe for Function
impl Send for Function
impl Sync for Function
impl Unpin for Function
impl UnsafeUnpin for Function
impl UnwindSafe for Function
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