INNER CODE UNIT · Rust
n
fuzzland/ityfuzz · src/evm/middlewares/cheatcode/mod.rs:579
let n = (op - opcode::LOG0) as usize;
let mut topics = Vec::with_capacity(n);
// Start from idx 2. The first two elements are the offset and len of the data.
for i in 2..(n + 2) {
let topic = interp.stack().peek(i)?;
topics.push(B256::from(topic.to_be_bytes()));
}
Ok(topics)
}
fn try_memory_resize(interp: &mut Interpreter, offset: usize, len: usize) -> Result<(), InstructionResult> {
memory_resize!(interp, offset, len);
Ok(())
}
fn get_opcode_type(op: u8, interp: &Interpreter) -> OpcodeType {