pub enum Instruction {
Show 77 variants
Add {
token: AddOpcode,
ret: Ident,
lhs: Ident,
rhs: Ident,
},
Addi {
token: AddiOpcode,
ret: Ident,
lhs: Ident,
rhs: AsmImmediate,
},
And {
token: AndOpcode,
ret: Ident,
lhs: Ident,
rhs: Ident,
},
Andi {
token: AndiOpcode,
ret: Ident,
lhs: Ident,
rhs: AsmImmediate,
},
Div {
token: DivOpcode,
ret: Ident,
lhs: Ident,
rhs: Ident,
},
Divi {
token: DiviOpcode,
ret: Ident,
lhs: Ident,
rhs: AsmImmediate,
},
Eq {
token: EqOpcode,
ret: Ident,
lhs: Ident,
rhs: Ident,
},
Exp {
token: ExpOpcode,
ret: Ident,
base: Ident,
power: Ident,
},
Expi {
token: ExpiOpcode,
ret: Ident,
base: Ident,
power: AsmImmediate,
},
Gt {
token: GtOpcode,
ret: Ident,
lhs: Ident,
rhs: Ident,
},
Gtf {
token: GtfOpcode,
ret: Ident,
index: Ident,
tx_field_id: AsmImmediate,
},
Lt {
token: LtOpcode,
ret: Ident,
lhs: Ident,
rhs: Ident,
},
Mlog {
token: MlogOpcode,
ret: Ident,
arg: Ident,
base: Ident,
},
Mod {
token: ModOpcode,
ret: Ident,
lhs: Ident,
rhs: Ident,
},
Modi {
token: ModiOpcode,
ret: Ident,
lhs: Ident,
rhs: AsmImmediate,
},
Move {
token: MoveOpcode,
ret: Ident,
from: Ident,
},
Movi {
token: MoviOpcode,
ret: Ident,
arg: AsmImmediate,
},
Mroo {
token: MrooOpcode,
ret: Ident,
arg: Ident,
root: Ident,
},
Mul {
token: MulOpcode,
ret: Ident,
lhs: Ident,
rhs: Ident,
},
Muli {
token: MuliOpcode,
ret: Ident,
lhs: Ident,
rhs: AsmImmediate,
},
Noop {
token: NoopOpcode,
},
Not {
token: NotOpcode,
ret: Ident,
arg: Ident,
},
Or {
token: OrOpcode,
ret: Ident,
lhs: Ident,
rhs: Ident,
},
Ori {
token: OriOpcode,
ret: Ident,
lhs: Ident,
rhs: AsmImmediate,
},
Sll {
token: SllOpcode,
ret: Ident,
lhs: Ident,
rhs: Ident,
},
Slli {
token: SlliOpcode,
ret: Ident,
lhs: Ident,
rhs: AsmImmediate,
},
Smo {
token: SmoOpcode,
addr: Ident,
len: Ident,
output: Ident,
coins: Ident,
},
Srl {
token: SrlOpcode,
ret: Ident,
lhs: Ident,
rhs: Ident,
},
Srli {
token: SrliOpcode,
ret: Ident,
lhs: Ident,
rhs: AsmImmediate,
},
Sub {
token: SubOpcode,
ret: Ident,
lhs: Ident,
rhs: Ident,
},
Subi {
token: SubiOpcode,
ret: Ident,
lhs: Ident,
rhs: AsmImmediate,
},
Xor {
token: XorOpcode,
ret: Ident,
lhs: Ident,
rhs: Ident,
},
Xori {
token: XoriOpcode,
ret: Ident,
lhs: Ident,
rhs: AsmImmediate,
},
Cimv {
token: CimvOpcode,
ret: Ident,
input: Ident,
maturity: Ident,
},
Ctmv {
token: CtmvOpcode,
ret: Ident,
maturity: Ident,
},
Ji {
token: JiOpcode,
offset: AsmImmediate,
},
Jnei {
token: JneiOpcode,
lhs: Ident,
rhs: Ident,
offset: AsmImmediate,
},
Ret {
token: RetOpcode,
value: Ident,
},
Aloc {
token: AlocOpcode,
size: Ident,
},
Cfei {
token: CfeiOpcode,
size: AsmImmediate,
},
Cfsi {
token: CfsiOpcode,
size: AsmImmediate,
},
Lb {
token: LbOpcode,
ret: Ident,
addr: Ident,
offset: AsmImmediate,
},
Lw {
token: LwOpcode,
ret: Ident,
addr: Ident,
offset: AsmImmediate,
},
Mcl {
token: MclOpcode,
addr: Ident,
size: Ident,
},
Mcli {
token: McliOpcode,
addr: Ident,
size: AsmImmediate,
},
Mcp {
token: McpOpcode,
dst_addr: Ident,
src_addr: Ident,
size: Ident,
},
Mcpi {
token: McpiOpcode,
dst_addr: Ident,
src_addr: Ident,
size: AsmImmediate,
},
Meq {
token: MeqOpcode,
ret: Ident,
lhs_addr: Ident,
rhs_addr: Ident,
size: Ident,
},
Sb {
token: SbOpcode,
addr: Ident,
value: Ident,
offset: AsmImmediate,
},
Sw {
token: SwOpcode,
addr: Ident,
value: Ident,
offset: AsmImmediate,
},
Bal {
token: BalOpcode,
ret: Ident,
asset: Ident,
contract: Ident,
},
Bhei {
token: BheiOpcode,
ret: Ident,
},
Bhsh {
token: BhshOpcode,
addr: Ident,
height: Ident,
},
Burn {
token: BurnOpcode,
coins: Ident,
},
Call {
token: CallOpcode,
args_addr: Ident,
coins: Ident,
asset: Ident,
gas: Ident,
},
Cb {
token: CbOpcode,
addr: Ident,
},
Ccp {
token: CcpOpcode,
dst_addr: Ident,
contract: Ident,
src_addr: Ident,
size: Ident,
},
Croo {
token: CrooOpcode,
addr: Ident,
contract: Ident,
},
Csiz {
token: CsizOpcode,
ret: Ident,
contract: Ident,
},
Ldc {
token: LdcOpcode,
contract: Ident,
addr: Ident,
size: Ident,
},
Log {
token: LogOpcode,
reg_a: Ident,
reg_b: Ident,
reg_c: Ident,
reg_d: Ident,
},
Logd {
token: LogdOpcode,
reg_a: Ident,
reg_b: Ident,
addr: Ident,
size: Ident,
},
Mint {
token: MintOpcode,
coins: Ident,
},
Retd {
token: RetdOpcode,
addr: Ident,
size: Ident,
},
Rvrt {
token: RvrtOpcode,
value: Ident,
},
Sldc {
token: SldcOpcode,
contract: Ident,
addr: Ident,
size: Ident,
},
Srw {
token: SrwOpcode,
ret: Ident,
state_addr: Ident,
},
Srwq {
token: SrwqOpcode,
addr: Ident,
state_addr: Ident,
},
Sww {
token: SwwOpcode,
state_addr: Ident,
value: Ident,
},
Swwq {
token: SwwqOpcode,
state_addr: Ident,
addr: Ident,
},
Tr {
token: TrOpcode,
contract: Ident,
coins: Ident,
asset: Ident,
},
Tro {
token: TroOpcode,
addr: Ident,
output: Ident,
coins: Ident,
asset: Ident,
},
Ecr {
token: EcrOpcode,
addr: Ident,
sig: Ident,
hash: Ident,
},
K256 {
token: K256Opcode,
addr: Ident,
data: Ident,
size: Ident,
},
S256 {
token: S256Opcode,
addr: Ident,
data: Ident,
size: Ident,
},
Flag {
token: FlagOpcode,
value: Ident,
},
Gm {
token: GmOpcode,
ret: Ident,
op: AsmImmediate,
},
}
Variants
Add
Addi
And
Andi
Div
Divi
Eq
Exp
Expi
Gt
Gtf
Lt
Mlog
Mod
Modi
Move
Movi
Mroo
Mul
Muli
Noop
Fields
token: NoopOpcode
Not
Or
Ori
Sll
Slli
Smo
Srl
Srli
Sub
Subi
Xor
Xori
Cimv
Ctmv
Ji
Jnei
Ret
Aloc
Cfei
Cfsi
Lb
Lw
Mcl
Mcli
Mcp
Mcpi
Meq
Sb
Sw
Bal
Bhei
Bhsh
Burn
Call
Cb
Ccp
Croo
Csiz
Ldc
Log
Logd
Mint
Retd
Rvrt
Sldc
Srw
Srwq
Sww
Swwq
Tr
Tro
Ecr
K256
S256
Flag
Gm
Implementations
sourceimpl Instruction
impl Instruction
pub fn op_code_ident(&self) -> Ident
pub fn register_arg_idents(&self) -> Vec<Ident>
pub fn immediate_ident_opt(&self) -> Option<Ident>
Trait Implementations
sourceimpl Clone for Instruction
impl Clone for Instruction
sourcefn clone(&self) -> Instruction
fn clone(&self) -> Instruction
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for Instruction
impl Debug for Instruction
Auto Trait Implementations
impl RefUnwindSafe for Instruction
impl Send for Instruction
impl Sync for Instruction
impl Unpin for Instruction
impl UnwindSafe for Instruction
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more