Skip to content

Commit af7eec8

Browse files
committed
lets try this again
1 parent 6890be4 commit af7eec8

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

crates/evm/evm/src/inspectors/stack.rs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -355,6 +355,7 @@ impl InspectorStack {
355355

356356
impl<DB: DatabaseExt> Inspector<DB> for InspectorStack {
357357
fn initialize_interp(&mut self, interpreter: &mut Interpreter<'_>, data: &mut EVMData<'_, DB>) {
358+
let res = interpreter.instruction_result;
358359
call_inspectors!(
359360
[
360361
&mut self.debugger,
@@ -368,7 +369,7 @@ impl<DB: DatabaseExt> Inspector<DB> for InspectorStack {
368369
inspector.initialize_interp(interpreter, data);
369370

370371
// Allow inspectors to exit early
371-
if interpreter.instruction_result != InstructionResult::Continue {
372+
if interpreter.instruction_result != res {
372373
#[allow(clippy::needless_return)]
373374
return
374375
}
@@ -377,6 +378,7 @@ impl<DB: DatabaseExt> Inspector<DB> for InspectorStack {
377378
}
378379

379380
fn step(&mut self, interpreter: &mut Interpreter<'_>, data: &mut EVMData<'_, DB>) {
381+
let res = interpreter.instruction_result;
380382
call_inspectors!(
381383
[
382384
&mut self.fuzzer,
@@ -391,7 +393,7 @@ impl<DB: DatabaseExt> Inspector<DB> for InspectorStack {
391393
inspector.step(interpreter, data);
392394

393395
// Allow inspectors to exit early
394-
if interpreter.instruction_result != InstructionResult::Continue {
396+
if interpreter.instruction_result != res {
395397
#[allow(clippy::needless_return)]
396398
return
397399
}
@@ -415,6 +417,7 @@ impl<DB: DatabaseExt> Inspector<DB> for InspectorStack {
415417
}
416418

417419
fn step_end(&mut self, interpreter: &mut Interpreter<'_>, data: &mut EVMData<'_, DB>) {
420+
let res = interpreter.instruction_result;
418421
call_inspectors!(
419422
[
420423
&mut self.debugger,
@@ -428,7 +431,7 @@ impl<DB: DatabaseExt> Inspector<DB> for InspectorStack {
428431
inspector.step_end(interpreter, data);
429432

430433
// Allow inspectors to exit early
431-
if interpreter.instruction_result != InstructionResult::Continue {
434+
if interpreter.instruction_result != res {
432435
#[allow(clippy::needless_return)]
433436
return
434437
}

0 commit comments

Comments
 (0)