Skip to content

Commit

Permalink
fix read/write fallthrough check (#7126)
Browse files Browse the repository at this point in the history
  • Loading branch information
emo-eth authored Feb 14, 2024
1 parent e10b039 commit e9dad71
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions crates/debugger/src/tui/draw.rs
Original file line number Diff line number Diff line change
Expand Up @@ -518,12 +518,11 @@ impl DebuggerContext<'_> {
let stack_len = step.stack.len();
if stack_len > 0 {
if let Some(accesses) = get_buffer_accesses(op, &step.stack) {
if let Some(read_access) = accesses.read {
if read_access.0 == self.active_buffer {
offset = Some(read_access.1.offset);
size = Some(read_access.1.size);
color = Some(Color::Cyan);
}
if accesses.read.as_ref().is_some_and(|a| a.0 == self.active_buffer) {
let read_access = accesses.read.unwrap();
offset = Some(read_access.1.offset);
size = Some(read_access.1.size);
color = Some(Color::Cyan);
} else if let Some(write_access) = accesses.write {
// TODO: with MCOPY, it will be possible to both read from and write to the
// memory buffer with the same opcode
Expand Down

0 comments on commit e9dad71

Please sign in to comment.