Struct parity_wasm::elements::InitExpr [−][src]
pub struct InitExpr(_);
Initialization expression.
Methods
impl InitExpr[src]
impl InitExprpub fn new(code: Vec<Instruction>) -> Self[src]
pub fn new(code: Vec<Instruction>) -> SelfNew initialization expression from instruction list.
code must end with the Instruction::End instruction!
pub fn empty() -> Self[src]
pub fn empty() -> SelfEmpty expression with only Instruction::End instruction
pub fn code(&self) -> &[Instruction][src]
pub fn code(&self) -> &[Instruction]List of instructions used in the expression.
pub fn code_mut(&mut self) -> &mut Vec<Instruction>[src]
pub fn code_mut(&mut self) -> &mut Vec<Instruction>List of instructions used in the expression.
Trait Implementations
impl Debug for InitExpr[src]
impl Debug for InitExprfn fmt(&self, f: &mut Formatter) -> Result[src]
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl Clone for InitExpr[src]
impl Clone for InitExprfn clone(&self) -> InitExpr[src]
fn clone(&self) -> InitExprReturns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
fn clone_from(&mut self, source: &Self)1.0.0
[src]Performs copy-assignment from source. Read more
impl PartialEq for InitExpr[src]
impl PartialEq for InitExprfn eq(&self, other: &InitExpr) -> bool[src]
fn eq(&self, other: &InitExpr) -> boolThis method tests for self and other values to be equal, and is used by ==. Read more
fn ne(&self, other: &InitExpr) -> bool[src]
fn ne(&self, other: &InitExpr) -> boolThis method tests for !=.
impl Deserialize for InitExpr[src]
impl Deserialize for InitExprtype Error = Error
Serialization error produced by deserialization routine.
fn deserialize<R: Read>(reader: &mut R) -> Result<Self, Self::Error>[src]
fn deserialize<R: Read>(reader: &mut R) -> Result<Self, Self::Error>Deserialize type from serial i/o
impl Serialize for InitExpr[src]
impl Serialize for InitExpr