1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
use cfx_types::{Address, U256};

pub trait InterpreterInfo {
    fn gas_remainning(&self) -> U256;

    fn program_counter(&self) -> u64;

    fn current_opcode(&self) -> u8;

    fn opcode(&self, pc: u64) -> Option<u8>;

    fn mem(&self) -> &Vec<u8>;

    fn stack(&self) -> &Vec<U256>;

    fn return_stack(&self) -> &Vec<usize>;

    fn contract_address(&self) -> Address;
}