Skip to content

Commit

Permalink
add docs
Browse files Browse the repository at this point in the history
  • Loading branch information
FredCoen committed Jan 30, 2025
1 parent ba4e64e commit e62deb0
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion examples/instruction_table_override/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
//! Example of a customizing the instruction table.
//!
//! Introduces a custom CLZ opcode.
use crate::exec::transact_custom_opcode;
use database::{BenchmarkDB, FFADDRESS};
use revm::{context::Context, primitives::TxKind, state::Bytecode};
Expand Down Expand Up @@ -26,5 +29,5 @@ fn main() {
});

let result = transact_custom_opcode(&mut ctx).expect("execution failed");
println!("Should return 0xff (255 in decimal) which is the clz of 256 bit value 0x01. The actual return is: {}", result.result.output().unwrap());
println!("Should return 0xff (255 in decimal) which is the clz of 256 bit value 0x01. The actual returned value is: {}", result.result.output().unwrap());
}

0 comments on commit e62deb0

Please sign in to comment.