pub trait Opcode:
From<Self::Mnemonic>
+ Send
+ Sync
+ FromPrimitive
+ ToPrimitive
+ Copy
+ Clone
+ Debug {
type Mnemonic;
Show 13 methods
// Required methods
fn has_arg(&self) -> bool;
fn has_extended_arg(&self) -> bool;
fn has_const(&self) -> bool;
fn has_comp(&self) -> bool;
fn is_other_conditional_jump(&self) -> bool;
fn is_relative_jump(&self) -> bool;
fn is_absolute_jump(&self) -> bool;
fn is_conditional_jump(&self) -> bool;
fn has_name(&self) -> bool;
fn has_local(&self) -> bool;
fn has_free(&self) -> bool;
fn mnemonic(&self) -> Self::Mnemonic;
// Provided method
fn is_jump(&self) -> bool { ... }
}
Expand description
Trait that provides convenience routines for opcode properties such as whether or not it has an argument, is a jump, etc.
Required Associated Types§
Required Methods§
Sourcefn has_extended_arg(&self) -> bool
fn has_extended_arg(&self) -> bool
Whether or not this opcode has an extended argument
fn is_other_conditional_jump(&self) -> bool
Sourcefn is_relative_jump(&self) -> bool
fn is_relative_jump(&self) -> bool
Whether or not this opcode has a relative jump target
Sourcefn is_absolute_jump(&self) -> bool
fn is_absolute_jump(&self) -> bool
Whether or not this opcode has an absolute jump target
Sourcefn is_conditional_jump(&self) -> bool
fn is_conditional_jump(&self) -> bool
Whether or not this opcode is a conditional jump
fn mnemonic(&self) -> Self::Mnemonic
Provided Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.