kkrt-labs/cairo-vm-ts

refactor: get rid of `deduce()` methods to compute operands

Closed this issue · 0 comments

The current computeOperands() method is based on the production vm in Rust:

  • Compute the operand address
  • Read the value at the computed address
  • If the read memory cell is empty, deduce the operand value from the other operands with deduce()

Burying this logic in multiple methods with their own switch-case flow is confusing. It can, and should be done in a simpler way, straightforwardly.