tengo icon indicating copy to clipboard operation
tengo copied to clipboard

Debugging: Ability to set a breakpoint and trace?

Open gunnsth opened this issue 2 years ago • 1 comments

This is probably a feature request, but it would be nice if it was possible to do something like

tdb := import("tdb")
tdb.set_trace()

(similar to pdb in python), which would give a prompt, similar to the REPL prompt in the tengo CLI command and use to print state of variables and such.

gunnsth avatar Jun 22 '22 18:06 gunnsth

There already is the OpSuspend instruction to suspend the run of the VM, but there's yet no way to continue after suspending. Perhaps that could be added to enable debugging?

beoran avatar Jul 21 '22 09:07 beoran