summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGabriel Kerneis2014-06-09 15:02:13 +0100
committerGabriel Kerneis2014-06-09 15:02:13 +0100
commit9205142009c2ba2adda38626c92bc71f5d444a97 (patch)
tree4fc84ccbffbb46a5699151370a77cf97752c60ef /src
parent3fb0cd60627d19ba49dc789afe94ea135fc13d35 (diff)
Add "continuation" command in interpreter
This displays the full continuation of the current breakpoint, which is basically the closest that we have from the "context" requested by Peter. Especially using it after the "execute" breakpoint shows the code of the instruction to be executed.
Diffstat (limited to 'src')
-rw-r--r--src/lem_interp/run_interp.ml5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/lem_interp/run_interp.ml b/src/lem_interp/run_interp.ml
index 16ec976a..38336b4d 100644
--- a/src/lem_interp/run_interp.ml
+++ b/src/lem_interp/run_interp.ml
@@ -264,6 +264,7 @@ let run
next go to next break point [default]
run complete current execution,
stack print call stack
+ cont print continuation of the top stack frame
env print content of environment
mem print content of memory
quit exit interpreter" in
@@ -281,6 +282,10 @@ let run
| "s" | "stack" ->
List.iter print_exp (compact_stack stack);
interact env stack
+ | "c" | "cont" | "continuation" ->
+ (* print not-compacted continuation *)
+ print_exp (top_frame_exp stack);
+ interact env stack
| "show_casts" ->
Pretty_interp.ignore_casts := false;
interact env stack