From 12c3ee1e4576f13808e962b2f818fb5d61466e9d Mon Sep 17 00:00:00 2001 From: "Kartik K. Agaram" Date: Tue, 2 Jun 2015 00:48:32 -0700 Subject: 1520 - repl kinda working But we really should test the top-level integration with 'run-interactive'. --- 078run_interactive.cc | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) (limited to '078run_interactive.cc') diff --git a/078run_interactive.cc b/078run_interactive.cc index 1075c922..910147f1 100644 --- a/078run_interactive.cc +++ b/078run_interactive.cc @@ -19,7 +19,7 @@ case RUN_INTERACTIVE: { // just an integer prints value of that location in memory // instruction executes // backspace at start begins new attempt -// ctrl-d working [not after first instruction is run] +// ctrl-d working void run_interactive(long long int address) { //? tb_shutdown(); //? 1 long long int size = Memory[address]; @@ -61,3 +61,15 @@ void run_interactive(long long int address) { //? cerr << "interactive transformed_until: " << Recipe[Recipe_number["interactive"]].transformed_until << '\n'; //? 1 Current_routine->calls.push_front(call(Recipe_number["interactive"])); } + +//:: debugging tool + +:(before "End Primitive Recipe Declarations") +_RUN_DEPTH, +:(before "End Primitive Recipe Numbers") +Recipe_number["$run-depth"] = _RUN_DEPTH; +:(before "End Primitive Recipe Implementations") +case _RUN_DEPTH: { + cerr << Current_routine->calls.size(); + break; +} -- cgit 1.4.1-2-gfad0