evm_opcodes

Trait OpCode

Source
pub trait OpCode: From<u8> + Into<u8> {
    // Required methods
    fn stack_in(&self) -> u16;
    fn stack_out(&self) -> u16;
    fn since(&self) -> Upgrade;
    fn group(&self) -> Group;
    fn gas(&self) -> u16;
}
Expand description

Ethereum virtual machine opcode.

Required Methods§

Source

fn stack_in(&self) -> u16

The stack input count.

Source

fn stack_out(&self) -> u16

The stack output count.

Source

fn since(&self) -> Upgrade

The OpCode is available since.

Source

fn group(&self) -> Group

The group of the OpCode.

Source

fn gas(&self) -> u16

The basic gas cost of the OpCode.

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.

Implementors§