Hello,
I'm looking for the ways to list the statement/expressions executed while running a simple kotlin program (like beginner level). As if you set a breakline of each of your kotlin program's line of code: I need to tell which statements were reached in which order with which variable values.
So far I found:
• either use the usual debugger, but that requires IJ.
• run the program as a script with jsr223, but that will only output the result and not show individual steps, plus it's hard to extract the variable's content.
• Write my own interpreter using ANTLR? I had a look at that yesterday and it's going to be a nightmare to reimplement all the logic...
• Java command line debugger?
Anything else?
or it might be easier to instrument the bytecode, write a javaagent which adds additional logging to the bytecode, sounds like it would be enough for what you're doing