diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2012-01-21 10:58:50 -0800 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2012-01-21 10:58:50 -0800 |
commit | d4d41b4ec3f983ad0fa42f8e85a2c68d207a9b28 (patch) | |
tree | d4c22f7c06cdb64772ffe58b7e0bccb0ae3c4822 | |
parent | 66ab83b942d8f0f6a4c27f171b361e08680f5a34 (diff) | |
download | txr-d4d41b4ec3f983ad0fa42f8e85a2c68d207a9b28.tar.gz txr-d4d41b4ec3f983ad0fa42f8e85a2c68d207a9b28.tar.bz2 txr-d4d41b4ec3f983ad0fa42f8e85a2c68d207a9b28.zip |
* debug.c (help): Filled in.
(debug): Some commands changed due to duplicates.
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | debug.c | 18 |
2 files changed, 18 insertions, 5 deletions
@@ -1,5 +1,10 @@ 2012-01-21 Kaz Kylheku <kaz@kylheku.com> + * debug.c (help): Filled in. + (debug): Some commands changed due to duplicates. + +2012-01-21 Kaz Kylheku <kaz@kylheku.com> + * match.c (v_fun): Removing all debugging instrumentation. (match_files): Moving debug_check out of directive case so it covers all forms handled by loop. All this makes the n @@ -22,8 +22,16 @@ static int next_depth = -1; val breakpoints; val last_command = lit(""); -static void help(void) +static void help(val stream) { + put_string(stream, + lit("commands:\n" + "? - help s - step into form\n" + "h - help n - step over form\n" + "c - continue f - finish form\n" + "v - show variable binding environment s - show current form\n" + "b - set breakpoint by line number i - show current data\n" + "d - delete breakpoint l - list breakpoints\n")); } static void show_bindings(val env, val stream) @@ -91,8 +99,8 @@ val debug(val form, val bindings, val data, val line, val chr) last_command, first(input)); last_command = command; - if (equal(command, lit("?")) || equal(command, lit("help"))) { - help(); + if (equal(command, lit("?")) || equal(command, lit("h"))) { + help(std_output); continue; } else if (equal(command, null_string)) { continue; @@ -113,9 +121,9 @@ val debug(val form, val bindings, val data, val line, val chr) return nil; } else if (equal(command, lit("v"))) { show_bindings(bindings, std_output); - } else if (equal(command, lit("i"))) { + } else if (equal(command, lit("s"))) { print_form = t; - } else if (equal(command, lit("d"))) { + } else if (equal(command, lit("i"))) { print_data = t; } else if (equal(command, lit("b")) || equal(command, lit("d"))) { if (!rest(input)) { |