pub struct FunctionDef {
pub name: String,
pub is_public: bool,
pub is_entry: bool,
pub parameters: Vec<TypeTag>,
pub returns: Vec<TypeTag>,
pub locals: Vec<TypeTag>,
pub code: Vec<MoveOpcode>,
}Expand description
A function definition
Fields§
§name: StringFunction name
is_public: boolIs this a public function?
is_entry: boolIs this an entry function?
parameters: Vec<TypeTag>Parameter types
returns: Vec<TypeTag>Return types
locals: Vec<TypeTag>Local slot layout (parameters are always the first locals)
code: Vec<MoveOpcode>Function body (opcodes)
Trait Implementations§
Source§impl Clone for FunctionDef
impl Clone for FunctionDef
Source§fn clone(&self) -> FunctionDef
fn clone(&self) -> FunctionDef
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for FunctionDef
impl RefUnwindSafe for FunctionDef
impl Send for FunctionDef
impl Sync for FunctionDef
impl Unpin for FunctionDef
impl UnwindSafe for FunctionDef
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