Skip to content

Commit

Permalink
Include top item of Object Stack in VM debug output
Browse files Browse the repository at this point in the history
  • Loading branch information
acook committed Mar 10, 2024
1 parent 1471e7e commit ad3a5a7
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/vm_state.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,12 @@ func (vm *VMstate) debug() {
print("\n")
}

if vm.m.ObjectStack.Depth() > 0 {
print(" top of object stack: ")
print(vm.m.ObjectStack.Peek().Refl())
print("\n")
}

print(" @ stack: ")
print(vm.m.Current().Refl())
print("\n")
Expand Down

0 comments on commit ad3a5a7

Please sign in to comment.